x86: mtrr: if: remove use of seq_printf return value
The seq_printf return value, because it's frequently misused,
will eventually be converted to void.
See: commit 1f33c41c03
("seq_file: Rename seq_overflow() to
seq_has_overflowed() and make public")
Signed-off-by: Joe Perches <joe@perches.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
committed by
Linus Torvalds
parent
89c1e79eb3
commit
3ac62bc060
@@ -404,11 +404,10 @@ static const struct file_operations mtrr_fops = {
|
|||||||
static int mtrr_seq_show(struct seq_file *seq, void *offset)
|
static int mtrr_seq_show(struct seq_file *seq, void *offset)
|
||||||
{
|
{
|
||||||
char factor;
|
char factor;
|
||||||
int i, max, len;
|
int i, max;
|
||||||
mtrr_type type;
|
mtrr_type type;
|
||||||
unsigned long base, size;
|
unsigned long base, size;
|
||||||
|
|
||||||
len = 0;
|
|
||||||
max = num_var_ranges;
|
max = num_var_ranges;
|
||||||
for (i = 0; i < max; i++) {
|
for (i = 0; i < max; i++) {
|
||||||
mtrr_if->get(i, &base, &size, &type);
|
mtrr_if->get(i, &base, &size, &type);
|
||||||
@@ -425,11 +424,10 @@ static int mtrr_seq_show(struct seq_file *seq, void *offset)
|
|||||||
size >>= 20 - PAGE_SHIFT;
|
size >>= 20 - PAGE_SHIFT;
|
||||||
}
|
}
|
||||||
/* Base can be > 32bit */
|
/* Base can be > 32bit */
|
||||||
len += seq_printf(seq, "reg%02i: base=0x%06lx000 "
|
seq_printf(seq, "reg%02i: base=0x%06lx000 (%5luMB), size=%5lu%cB, count=%d: %s\n",
|
||||||
"(%5luMB), size=%5lu%cB, count=%d: %s\n",
|
i, base, base >> (20 - PAGE_SHIFT),
|
||||||
i, base, base >> (20 - PAGE_SHIFT), size,
|
size, factor,
|
||||||
factor, mtrr_usage_table[i],
|
mtrr_usage_table[i], mtrr_attrib_to_str(type));
|
||||||
mtrr_attrib_to_str(type));
|
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user