你可以使用Contains方法:
Contains
var result=context.avatars.Where(a => userIds.Contains(a.userId));
或者Any:
Any
var result=context.avatars.Where(a => userIds.Any(e=>a.userId==e));