[PATCH 1/2] list: rename debugging hooks

Sascha Hauer sha at pengutronix.de
Thu Jan 4 01:12:21 PST 2024


On Wed, Jan 03, 2024 at 11:19:47AM +0100, Ahmad Fatoum wrote:
> Linux recently renamed the name of these helpers, so have barebox follow
> suit before implementing them out of line when optional list debugging
> is enabled.
> 
> Signed-off-by: Ahmad Fatoum <a.fatoum at pengutronix.de>
> ---
>  include/linux/list.h | 20 ++++++++++----------
>  1 file changed, 10 insertions(+), 10 deletions(-)

Applied, thanks

Sascha

> 
> diff --git a/include/linux/list.h b/include/linux/list.h
> index 1341806b59da..60b0111f467c 100644
> --- a/include/linux/list.h
> +++ b/include/linux/list.h
> @@ -37,18 +37,18 @@ static inline void INIT_LIST_HEAD(struct list_head *list)
>  }
>  
>  #ifdef CONFIG_DEBUG_LIST
> -extern bool __list_add_valid(struct list_head *new,
> -			      struct list_head *prev,
> -			      struct list_head *next);
> -extern bool __list_del_entry_valid(struct list_head *entry);
> +extern bool __list_add_valid_or_report(struct list_head *new,
> +				       struct list_head *prev,
> +				       struct list_head *next);
> +extern bool __list_del_entry_valid_or_report(struct list_head *entry);
>  #else
> -static inline bool __list_add_valid(struct list_head *new,
> -				struct list_head *prev,
> -				struct list_head *next)
> +static inline bool __list_add_valid_or_report(struct list_head *new,
> +					      struct list_head *prev,
> +					      struct list_head *next)
>  {
>  	return true;
>  }
> -static inline bool __list_del_entry_valid(struct list_head *entry)
> +static inline bool __list_del_entry_valid_or_report(struct list_head *entry)
>  {
>  	return true;
>  }
> @@ -64,7 +64,7 @@ static inline void __list_add(struct list_head *new,
>  			      struct list_head *prev,
>  			      struct list_head *next)
>  {
> -	if (!__list_add_valid(new, prev, next))
> +	if (!__list_add_valid_or_report(new, prev, next))
>  		return;
>  
>  	next->prev = new;
> @@ -129,7 +129,7 @@ static inline void __list_del_clearprev(struct list_head *entry)
>  
>  static inline void __list_del_entry(struct list_head *entry)
>  {
> -	if (!__list_del_entry_valid(entry))
> +	if (!__list_del_entry_valid_or_report(entry))
>  		return;
>  
>  	__list_del(entry->prev, entry->next);
> -- 
> 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 |



More information about the barebox mailing list