On 25/08/17 11:56, Volodymyr Babchuk wrote:
Hi Julien,
Hi Volodymyr,
On 24.08.17 19:58, Julien Grall wrote:
+ case ARM_SMCCC_FUNC_CALL_COUNT:
+ set_user_reg(regs, 0, SSSC_SMCCC_FUNCTION_COUNT);
+ return true;
+ case ARM_SMCCC_FUNC_CALL_UID:
+ {
+ static const xen_uuid_t psci_uuid = SSSC_SMCCC_UID;
Newline here please. But can't we just do:
return fill_uuid(regs, SSC_SMCCC_UID);
This would make the code simpler.
I'm not sure that I got this. fill_uuid() returns void, while
handle_sssc() returns bool.
You could make fill_uuid() returning a bool. Overall every caller of
fill_uuid will do:
fill_uuid(....);
return true;
+ fill_uuid(regs, psci_uuid);
+ return true;
+ }
+ case ARM_SMCCC_FUNC_CALL_REVISION:
+ set_user_reg(regs, 0, SSSC_SMCCC_MAJOR_REVISION);
+ set_user_reg(regs, 1, SSSC_SMCCC_MINOR_REVISION);
Same here.
Under "same" you meant newline, correct?
Hmmm, I don't remember :/. Although, we may want to introduce a helper
to fill the revision. Those wrapper would simplify the implementation of
"generic" function.
Cheers,
--
Julien Grall
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel