Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4395eb1f authored by Joe Perches's avatar Joe Perches Committed by Linus Torvalds
Browse files

rtc: 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 1f33c41c ("seq_file: Rename seq_overflow() to
     seq_has_overflowed() and make public")

Signed-off-by: default avatarJoe Perches <joe@perches.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 9f6a240e
Loading
Loading
Loading
Loading
+19 −17
Original line number Diff line number Diff line
@@ -459,7 +459,7 @@ static int cmos_procfs(struct device *dev, struct seq_file *seq)
	/* NOTE:  at least ICH6 reports battery status using a different
	 * (non-RTC) bit; and SQWE is ignored on many current systems.
	 */
	return seq_printf(seq,
	seq_printf(seq,
		   "periodic_IRQ\t: %s\n"
		   "update_IRQ\t: %s\n"
		   "HPET_emulated\t: %s\n"
@@ -476,6 +476,8 @@ static int cmos_procfs(struct device *dev, struct seq_file *seq)
		   (rtc_control & RTC_DST_EN) ? "yes" : "no",
		   cmos->rtc->irq_freq,
		   (valid & RTC_VRT) ? "okay" : "dead");

	return 0;
}

#else
+3 −3
Original line number Diff line number Diff line
@@ -434,9 +434,9 @@ static int ds1305_proc(struct device *dev, struct seq_file *seq)
	}

done:
	return seq_printf(seq,
			"trickle_charge\t: %s%s\n",
			diodes, resistors);
	seq_printf(seq, "trickle_charge\t: %s%s\n", diodes, resistors);

	return 0;
}

#else
+9 −7
Original line number Diff line number Diff line
@@ -277,13 +277,15 @@ static int mrst_procfs(struct device *dev, struct seq_file *seq)
	valid = vrtc_cmos_read(RTC_VALID);
	spin_unlock_irq(&rtc_lock);

	return seq_printf(seq,
	seq_printf(seq,
		   "periodic_IRQ\t: %s\n"
		   "alarm\t\t: %s\n"
		   "BCD\t\t: no\n"
		   "periodic_freq\t: daily (not adjustable)\n",
		   (rtc_control & RTC_PIE) ? "on" : "off",
		   (rtc_control & RTC_AIE) ? "on" : "off");

	return 0;
}

#else
+3 −1
Original line number Diff line number Diff line
@@ -261,7 +261,9 @@ static int tegra_rtc_proc(struct device *dev, struct seq_file *seq)
	if (!dev || !dev->driver)
		return 0;

	return seq_printf(seq, "name\t\t: %s\n", dev_name(dev));
	seq_printf(seq, "name\t\t: %s\n", dev_name(dev));

	return 0;
}

static irqreturn_t tegra_rtc_irq_handler(int irq, void *data)