mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <sha@pengutronix.de>
To: Ahmad Fatoum <a.fatoum@pengutronix.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH] include: move PATH_MAX from fs.h to linux/limits.h
Date: Fri, 9 Jun 2023 08:45:24 +0200	[thread overview]
Message-ID: <20230609064524.GQ18491@pengutronix.de> (raw)
In-Reply-To: <20230608072400.3275489-1-a.fatoum@pengutronix.de>

On Thu, Jun 08, 2023 at 09:24:00AM +0200, Ahmad Fatoum wrote:
> Linux defines PATH_MAX in <linux/limits.h> and code that just wants
> PATH_MAX to format a path may not be interested in all the other stuff
> defined in fs.h. Thus move PATH_MAX to <linux/limits.h> instead.
> 
> Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
> ---
>  include/fs.h           | 3 +--
>  include/linux/limits.h | 2 ++
>  2 files changed, 3 insertions(+), 2 deletions(-)

Applied, thanks

Sascha

> 
> diff --git a/include/fs.h b/include/fs.h
> index c64e78b38cf9..a61982e59ade 100644
> --- a/include/fs.h
> +++ b/include/fs.h
> @@ -12,8 +12,7 @@
>  #include <filetype.h>
>  #include <linux/fs.h>
>  #include <linux/string.h>
> -
> -#define PATH_MAX       1024        /* include/linux/limits.h */
> +#include <linux/limits.h>
>  
>  struct partition;
>  struct node_d;
> diff --git a/include/linux/limits.h b/include/linux/limits.h
> index 17375ef5225e..8baf8494943e 100644
> --- a/include/linux/limits.h
> +++ b/include/linux/limits.h
> @@ -35,4 +35,6 @@
>  #define S64_MAX		((s64)(U64_MAX >> 1))
>  #define S64_MIN		((s64)(-S64_MAX - 1))
>  
> +#define PATH_MAX       1024
> +
>  #endif /* _LINUX_LIMITS_H */
> -- 
> 2.39.2
> 
> 
> 

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |



      reply	other threads:[~2023-06-09  6:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-08  7:24 Ahmad Fatoum
2023-06-09  6:45 ` Sascha Hauer [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230609064524.GQ18491@pengutronix.de \
    --to=sha@pengutronix.de \
    --cc=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox