diff mbox series

[v1,1/1] mtd: Drop superfluous const qualifier

Message ID 20241021142040.2981390-1-andriy.shevchenko@linux.intel.com
State New
Delegated to: Dario Binacchi
Headers show
Series [v1,1/1] mtd: Drop superfluous const qualifier | expand

Commit Message

Andy Shevchenko Oct. 21, 2024, 2:20 p.m. UTC
The compiler will ignore it anyway:

  include/linux/mtd/mtd.h:342:15: warning: type qualifiers ignored on function return type [-Wignored-qualifiers]

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 include/linux/mtd/mtd.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Simon Glass Oct. 21, 2024, 4:32 p.m. UTC | #1
On Mon, 21 Oct 2024 at 16:20, Andy Shevchenko
<andriy.shevchenko@linux.intel.com> wrote:
>
> The compiler will ignore it anyway:
>
>   include/linux/mtd/mtd.h:342:15: warning: type qualifiers ignored on function return type [-Wignored-qualifiers]
>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> ---
>  include/linux/mtd/mtd.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>

Reviewed-by: Simon Glass <sjg@chromium.org>


> diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h
> index 6751fb52c5a5..3ffcd40807d0 100644
> --- a/include/linux/mtd/mtd.h
> +++ b/include/linux/mtd/mtd.h
> @@ -339,7 +339,7 @@ static inline void mtd_set_ofnode(struct mtd_info *mtd, ofnode node)
>         dev_set_ofnode(mtd->dev, node);
>  }
>
> -static inline const ofnode mtd_get_ofnode(struct mtd_info *mtd)
> +static inline ofnode mtd_get_ofnode(struct mtd_info *mtd)
>  {
>         return dev_ofnode(mtd->dev);
>  }
> --
> 2.43.0.rc1.1336.g36b5255a03ac
>
diff mbox series

Patch

diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h
index 6751fb52c5a5..3ffcd40807d0 100644
--- a/include/linux/mtd/mtd.h
+++ b/include/linux/mtd/mtd.h
@@ -339,7 +339,7 @@  static inline void mtd_set_ofnode(struct mtd_info *mtd, ofnode node)
 	dev_set_ofnode(mtd->dev, node);
 }
 
-static inline const ofnode mtd_get_ofnode(struct mtd_info *mtd)
+static inline ofnode mtd_get_ofnode(struct mtd_info *mtd)
 {
 	return dev_ofnode(mtd->dev);
 }