From: Andy Shevchenko Date: Thu, 17 Nov 2022 11:08:01 +0000 (+0200) Subject: pwm: lpss: Rename MAX_PWMS --> LPSS_MAX_PWMS X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=739f90fc48be7fb40f6dfe1212745c7fe56f2ab1;p=linux.git pwm: lpss: Rename MAX_PWMS --> LPSS_MAX_PWMS The MAX_PWMS definition is already being used by the PWM core. Using the same name in the certain driver confuses people and potentially can clash with it. Hence, rename it by adding LPSS prefix. Reported-by: Uwe Kleine-König Signed-off-by: Andy Shevchenko Acked-by: Thierry Reding Reviewed-by: Mika Westerberg Reviewed-by: Uwe Kleine-König --- diff --git a/drivers/pwm/pwm-lpss.c b/drivers/pwm/pwm-lpss.c index accdef5dd58e7..b8739cd2c2351 100644 --- a/drivers/pwm/pwm-lpss.c +++ b/drivers/pwm/pwm-lpss.c @@ -252,7 +252,7 @@ struct pwm_lpss_chip *pwm_lpss_probe(struct device *dev, void __iomem *base, int i, ret; u32 ctrl; - if (WARN_ON(info->npwm > MAX_PWMS)) + if (WARN_ON(info->npwm > LPSS_MAX_PWMS)) return ERR_PTR(-ENODEV); lpwm = devm_kzalloc(dev, sizeof(*lpwm), GFP_KERNEL); diff --git a/drivers/pwm/pwm-lpss.h b/drivers/pwm/pwm-lpss.h index 8e82eb5a7e009..2c746c51b8831 100644 --- a/drivers/pwm/pwm-lpss.h +++ b/drivers/pwm/pwm-lpss.h @@ -13,7 +13,7 @@ #include #include -#define MAX_PWMS 4 +#define LPSS_MAX_PWMS 4 struct pwm_lpss_chip { struct pwm_chip chip;