Lines Matching refs:count
29 long count = 0; in hwdep_read_resp_buf() local
78 count += till_end; in hwdep_read_resp_buf()
95 return count; in hwdep_read_resp_buf()
99 hwdep_read_locked(struct snd_efw *efw, char __user *buf, long count, in hwdep_read_locked() argument
113 count = min_t(long, count, sizeof(event.lock_status)); in hwdep_read_locked()
115 if (copy_to_user(buf, &event, count)) in hwdep_read_locked()
118 return count; in hwdep_read_locked()
122 hwdep_read(struct snd_hwdep *hwdep, char __user *buf, long count, in hwdep_read() argument
150 count = hwdep_read_locked(efw, buf, count, offset); in hwdep_read()
152 count = hwdep_read_resp_buf(efw, buf, count, offset); in hwdep_read()
154 return count; in hwdep_read()
158 hwdep_write(struct snd_hwdep *hwdep, const char __user *data, long count, in hwdep_write() argument
165 if (count < sizeof(struct snd_efw_transaction) || in hwdep_write()
166 SND_EFW_RESPONSE_MAXIMUM_BYTES < count) in hwdep_write()
169 buf = memdup_user(data, count); in hwdep_write()
176 count = -EINVAL; in hwdep_write()
180 if (snd_efw_transaction_cmd(efw->unit, buf, count) < 0) in hwdep_write()
181 count = -EIO; in hwdep_write()
184 return count; in hwdep_write()