[RFC PATCH 06/13] mux: Define a stub for mux_get_by_index if CONFIG_MUX is disabled

Pratyush Yadav p.yadav at ti.com
Fri Feb 5 11:53:30 CET 2021


On 04/02/21 11:39PM, Sean Anderson wrote:
> This allows code using mux_get_by_index to be agnostic about CONFIG_MUX.
> 
> Signed-off-by: Sean Anderson <seanga2 at gmail.com>
> ---
> 
>  include/mux.h | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/include/mux.h b/include/mux.h
> index 91a89bbb9a..882a00068b 100644
> --- a/include/mux.h
> +++ b/include/mux.h
> @@ -135,6 +135,12 @@ static inline int mux_control_deselect(struct mux_control *mux)
>  	return -ENOSYS;
>  }
>  
> +static inline int mux_get_by_index(struct udevice *dev, int index,
> +				   struct mux_control **mux)
> +{
> +	return -ENOSYS;
> +}
> +
>  static inline struct mux_control *mux_control_get(struct udevice *dev,
>  						  const char *mux_name)
>  {

Hmm... mux_control_get() on the other side of this ifdef has a 
completely different signature. Can you please add that fix in your 
series as well? For this patch,

Reviewed-by: Pratyush Yadav <p.yadav at ti.com>

-- 
Regards,
Pratyush Yadav
Texas Instruments Inc.


More information about the U-Boot mailing list