[U-Boot] [PATCH v3 11/11] sunxi: Add PSCI implementation in C

Chen-Yu Tsai wens at csie.org
Mon Jun 13 12:58:56 CEST 2016


On Mon, Jun 13, 2016 at 5:49 PM, Hans de Goede <hdegoede at redhat.com> wrote:
> Hi,
>
> On 13-06-16 04:50, Chen-Yu Tsai wrote:
>>
>> On Fri, Jun 10, 2016 at 9:40 PM, Hans de Goede <hdegoede at redhat.com>
>> wrote:
>>>
>>> Hi,
>>>
>>> On 07-06-16 04:54, Chen-Yu Tsai wrote:
>>>>
>>>>
>>>> To make the PSCI backend more maintainable and easier to port to newer
>>>> SoCs, rewrite the current PSCI implementation in C.
>>>>
>>>> Some inline assembly bits are required to access coprocessor registers.
>>>> PSCI stack setup is the only part left completely in assembly. In theory
>>>> this part could be split out of psci_arch_init into a separate common
>>>> function, and psci_arch_init could be completely in C.
>>>>
>>>> Signed-off-by: Chen-Yu Tsai <wens at csie.org>
>>>
>>>
>>>
>>> I tried merging this in my tree to add it to u-boot-sunxi/next, but
>>> unfortunately it triggers a bug in gcc-6.1, I've filed a bug with
>>> gcc to get this fixed:
>>>
>>> https://bugzilla.redhat.com/show_bug.cgi?id=1344717
>>
>>
>> Interesting. Seems like the compiler should be emitting LDMFD instead
>> of POP, or a POP followed by a SUBS/MOVS.
>>
>>>
>>> Also cp15_read_scr / cp15_write_scr are missing __secure notations.
>>
>>
>> Do you want me to send a new version for this?
>
>
> No, I already have a local branch with this fixed.
>
> As for getting this merged and Tom's "go for it"
> comment earlier, I consider this a blocker for merging, sorry.
>
> I hope that the gcc folks can resolve this soon and that I can
> get the Fedora devs to deploy a fix soon-ish. I'm not sure what
> other distros are doing wrt jumping to gcc-6.1, but having code
> in u-boot master which does not build with the latest gcc seems
> like a bad idea.

This is marked as resolved upstream:

    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70830

And Debian/Ubuntu seems to have pulled the fix into their latest
unstable package:

    http://metadata.ftp-master.debian.org/changelogs//main/g/gcc-6/gcc-6_6.1.1-6_changelog

I'm not familiar with Fedora, though you could reference the GCC
PR I listed above and have them pull in the fix.

Interesting that Fedora only provides one version of GCC though.

Regards
ChenYu

>
> Regards,
>
> Hans


More information about the U-Boot mailing list