In this case, we can group the combination of both visit and device like below so that we get repeated device for the same visit.
from s in db.Services.Where(condition)
where s.Active && (hasSupportGeneralAccess || s.Visit.Site.Branch.Users.Any(u => u.Id == userId)) && s.Device != null orderby s.Visit.Start descending
group s by (s.Visit + "." + s.Device) into newgroup
select newgroup.FirstOrDefault();
CLICK HERE to find out more related problems solutions.