Skip to content

Commit

Permalink
xtensa: update *pos in cpuinfo_op.next
Browse files Browse the repository at this point in the history
Increment *pos in the cpuinfo_op.next to fix the following warning
triggered by cat /proc/cpuinfo:

  seq_file: buggy .next function c_next did not update position index

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
  • Loading branch information
jcmvbkbc committed Jul 2, 2020
1 parent 73f9941 commit 0d5ab14
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion arch/xtensa/kernel/setup.c
Expand Up @@ -724,7 +724,8 @@ c_start(struct seq_file *f, loff_t *pos)
static void *
c_next(struct seq_file *f, void *v, loff_t *pos)
{
return NULL;
++*pos;
return c_start(f, pos);
}

static void
Expand Down

0 comments on commit 0d5ab14

Please sign in to comment.