* Andrew F. Davis <afd@xxxxxx> [200220 10:23]: > On 2/20/20 1:11 PM, Tony Lindgren wrote: > > * Tony Lindgren <tony@xxxxxxxxxxx> [200220 17:58]: > >> * Andrew F. Davis <afd@xxxxxx> [200220 17:39]: > >>> If the machine has SMCCC then it will also have the > >>> CONFIG_HAVE_ARM_SMCCC set and so nothing would change. > >> > >> Hmm yeah good point. > > > > So the patch below seems like the way to go then. Anybody have issues > > with the patch below? > > > > Regards, > > > > Tony > > > > 8< ------------------------- > > diff --git a/include/linux/arm-smccc.h b/include/linux/arm-smccc.h > > --- a/include/linux/arm-smccc.h > > +++ b/include/linux/arm-smccc.h > > @@ -121,6 +121,7 @@ struct arm_smccc_quirk { > > } state; > > }; > > > > +#ifdef CONFIG_HAVE_ARM_SMCCC > > /** > > * __arm_smccc_smc() - make SMC calls > > * @a0-a7: arguments passed in registers 0 to 7 > > @@ -137,6 +138,14 @@ asmlinkage void __arm_smccc_smc(unsigned long a0, unsigned long a1, > > unsigned long a2, unsigned long a3, unsigned long a4, > > unsigned long a5, unsigned long a6, unsigned long a7, > > struct arm_smccc_res *res, struct arm_smccc_quirk *quirk); > > +#else > > +static inline void __arm_smccc_smc(unsigned long a0, unsigned long a1, > > + unsigned long a2, unsigned long a3, unsigned long a4, > > + unsigned long a5, unsigned long a6, unsigned long a7, > > + struct arm_smccc_res *res, struct arm_smccc_quirk *quirk) > > +{ > > > Maybe a warning? If you do not have SMC on your platform but are still > making SMC calls then something is broken and it looks like it would > fail silently here. OK I'll add that and send out a proper patch. Thanks, Tony