Page MenuHomeFreeBSD

Convert the A20 and A10 to plaform.
ClosedPublic

Authored by manu_bidouilliste.com on Jan 24 2016, 9:37 PM.
Tags
Referenced Files
Unknown Object (File)
Apr 30 2024, 1:37 AM
Unknown Object (File)
Apr 30 2024, 1:32 AM
Unknown Object (File)
Dec 20 2023, 12:48 AM
Unknown Object (File)
Nov 19 2023, 3:39 PM
Unknown Object (File)
Oct 5 2023, 9:21 PM
Unknown Object (File)
Jul 3 2023, 6:56 PM
Unknown Object (File)
Jun 11 2023, 8:57 AM
Unknown Object (File)
Mar 23 2023, 6:27 AM

Details

Summary

Add allwinner_soc_type and allwinner_soc_family function that return the current SoC type and family based on what the attach machdep function set.

Add include files that contain all the Allwinner Soc type and family defines.

Use ARM_INTRNG and generic_timer for A20 SoC a10-timer is now only used on a10 SoC.

Test Plan

Apply patch and compile kernel for A20 or one of the A10 based platform (CUBIEBOARD for example).

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

manu_bidouilliste.com retitled this revision from to Convert the A20 and A10 to plaform..
manu_bidouilliste.com updated this object.
manu_bidouilliste.com edited the test plan for this revision. (Show Details)
sys/arm/allwinner/allwinner_machdep.c
141–142 ↗(On Diff #12656)
u_int
allwinner_soc_type(void)
{
sys/arm/allwinner/allwinner_machdep.h
5 ↗(On Diff #12656)

Is this correct?

31 ↗(On Diff #12656)

Should be

#ifndef _ALLWINNER_MACHDEP_H_
#define<tab>_ALLWINNER_MACHDEP_H_
33 ↗(On Diff #12656)

All .c files should have included this before including this file

sys/arm/allwinner/timer.c
152–153 ↗(On Diff #12656)

Have you hit this? We would expect the devicetree to be correct for the hardware.

Add answer to inline comments

sys/arm/allwinner/allwinner_machdep.h
5 ↗(On Diff #12656)

Yes this is the original licence from a10_machdep.c

sys/arm/allwinner/timer.c
152–153 ↗(On Diff #12656)

Yes, upstream a20 DTS also have the sun4i-a10-timer node

manu_bidouilliste.com marked 2 inline comments as done.

Fix style(9).
Sorry wrong cherry-pick ...

manu_bidouilliste.com marked 2 inline comments as done.
sys/arm/allwinner/allwinner_machdep.h
5 ↗(On Diff #12657)

I don't see anything in this file that would require us to keep this notice, it looks like you've written everything other than the standard license.

sys/arm/allwinner/timer.c
152–153 ↗(On Diff #12657)

Ok, move this change to the update fdt review as it's also includes a compatibility string change.

sys/arm/conf/A20
62 ↗(On Diff #12659)

I think this also depends on the dts change. If so move it to that change & move timer.c back to files.allwinner

sys/arm/conf/A20
62 ↗(On Diff #12659)

And what about gic and ARM_INTRNG ?
Should I also move them to the fdt change ? Or do another review that handle timer and gic ?

sys/arm/conf/A20
62 ↗(On Diff #12659)

If generic_timer relies on a change in the dts move it to the fdt change.

What gic change do you mean? The only related changes I see are to enable ARM_INTRNG. I don't see how this would be an issue.

sys/arm/conf/A20
62 ↗(On Diff #12659)

Yes you're right, I thought gic wasn't include in the original A20 file ... it's been a while.
For generic_timer is doesn't make sense right now are the our custom dts doesn't include the node.

Remove generic_timer for now as our custom DTS doesn't include the node.

Move timer.c to files.allwinner since A20 is still using it.

andrew added a reviewer: andrew.
This revision is now accepted and ready to land.Jan 25 2016, 12:24 AM
This revision was automatically updated to reflect the committed changes.