Lines Matching refs:count
28 long count = 0; in hwdep_read_resp_buf() local
65 count += till_end; in hwdep_read_resp_buf()
72 return count; in hwdep_read_resp_buf()
76 hwdep_read_locked(struct snd_efw *efw, char __user *buf, long count, in hwdep_read_locked() argument
87 count = min_t(long, count, sizeof(event.lock_status)); in hwdep_read_locked()
89 if (copy_to_user(buf, &event, count)) in hwdep_read_locked()
92 return count; in hwdep_read_locked()
96 hwdep_read(struct snd_hwdep *hwdep, char __user *buf, long count, in hwdep_read() argument
115 count = hwdep_read_locked(efw, buf, count, offset); in hwdep_read()
117 count = hwdep_read_resp_buf(efw, buf, count, offset); in hwdep_read()
121 return count; in hwdep_read()
125 hwdep_write(struct snd_hwdep *hwdep, const char __user *data, long count, in hwdep_write() argument
132 if (count < sizeof(struct snd_efw_transaction) || in hwdep_write()
133 SND_EFW_RESPONSE_MAXIMUM_BYTES < count) in hwdep_write()
136 buf = memdup_user(data, count); in hwdep_write()
143 count = -EINVAL; in hwdep_write()
147 if (snd_efw_transaction_cmd(efw->unit, buf, count) < 0) in hwdep_write()
148 count = -EIO; in hwdep_write()
151 return count; in hwdep_write()