|
@@ -629,7 +629,6 @@ ssize_t trace_seq_to_user(struct trace_seq *s, char __user *ubuf, size_t cnt)
|
|
|
static ssize_t trace_seq_to_buffer(struct trace_seq *s, void *buf, size_t cnt)
|
|
|
{
|
|
|
int len;
|
|
|
- void *ret;
|
|
|
|
|
|
if (s->len <= s->readpos)
|
|
|
return -EBUSY;
|
|
@@ -637,9 +636,7 @@ static ssize_t trace_seq_to_buffer(struct trace_seq *s, void *buf, size_t cnt)
|
|
|
len = s->len - s->readpos;
|
|
|
if (cnt > len)
|
|
|
cnt = len;
|
|
|
- ret = memcpy(buf, s->buffer + s->readpos, cnt);
|
|
|
- if (!ret)
|
|
|
- return -EFAULT;
|
|
|
+ memcpy(buf, s->buffer + s->readpos, cnt);
|
|
|
|
|
|
s->readpos += cnt;
|
|
|
return cnt;
|