Skip to content

Commit d5aca9a

Browse files
rddunlapalexandrebelloni
authored andcommitted
rtc: max31335: use correct CONFIG symbol in IS_REACHABLE()
IS_REACHABLE() is meant to be used with full symbol names from a kernel .config file, not the shortened symbols used in Kconfig files, so change HWMON to CONFIG_HWMON in 3 places. Fixes: dedaf03 ("rtc: max31335: add driver support") Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Acked-by: Nuno Sá <nuno.sa@analog.com> Link: https://patch.msgid.link/20260108045432.2705691-1-rdunlap@infradead.org Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
1 parent f9ecfd9 commit d5aca9a

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

drivers/rtc/rtc-max31335.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -591,7 +591,7 @@ static struct nvmem_config max31335_nvmem_cfg = {
591591
.size = MAX31335_RAM_SIZE,
592592
};
593593

594-
#if IS_REACHABLE(HWMON)
594+
#if IS_REACHABLE(CONFIG_HWMON)
595595
static int max31335_read_temp(struct device *dev, enum hwmon_sensor_types type,
596596
u32 attr, int channel, long *val)
597597
{
@@ -672,7 +672,7 @@ static int max31335_clkout_register(struct device *dev)
672672
static int max31335_probe(struct i2c_client *client)
673673
{
674674
struct max31335_data *max31335;
675-
#if IS_REACHABLE(HWMON)
675+
#if IS_REACHABLE(CONFIG_HWMON)
676676
struct device *hwmon;
677677
#endif
678678
const struct chip_desc *match;
@@ -727,7 +727,7 @@ static int max31335_probe(struct i2c_client *client)
727727
return dev_err_probe(&client->dev, ret,
728728
"cannot register rtc nvmem\n");
729729

730-
#if IS_REACHABLE(HWMON)
730+
#if IS_REACHABLE(CONFIG_HWMON)
731731
if (max31335->chip->temp_reg) {
732732
hwmon = devm_hwmon_device_register_with_info(&client->dev, client->name, max31335,
733733
&max31335_chip_info, NULL);

0 commit comments

Comments
 (0)