eeprom: at24: Improve confusing log message
authorJean Delvare <jdelvare@suse.de>
Fri, 4 Oct 2019 08:37:48 +0000 (10:37 +0200)
committerBartosz Golaszewski <bgolaszewski@baylibre.com>
Fri, 4 Oct 2019 08:46:39 +0000 (10:46 +0200)
commit285be87c79e173f08af5e1a6417a106fb14934b7
tree80ea9ccb16a4a1ed26296f996470eed7afb85c5d
parent54ecb8f7028c5eb3d740bb82b0f1d90f2df63c5c
eeprom: at24: Improve confusing log message

Currently when binding to an spd EEPROM, the at24 drivers logs the
following message:

256 byte spd EEPROM, read-only, 0 bytes/write

The last part is confusing, as by definition you don't write to a
read-only EEPROM, plus "0 bytes/write" makes no sense whatsoever.

I propose to have a different message for read-only EEPROMs, which
does not include this last part.

Signed-off-by: Jean Delvare <jdelvare@suse.de>
Cc: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Reviewed-by: Wolfram Sang <wsa@the-dreams.de>
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
drivers/misc/eeprom/at24.c