Page MenuHomeFreeBSD

Allwinner NMI driver
ClosedPublic

Authored by manu_bidouilliste.com on Mar 17 2016, 12:25 PM.
Tags
Referenced Files
Unknown Object (File)
Fri, Apr 12, 5:35 AM
Unknown Object (File)
Thu, Apr 11, 6:03 AM
Unknown Object (File)
Mon, Apr 8, 10:36 PM
Unknown Object (File)
Mar 19 2024, 6:14 AM
Unknown Object (File)
Feb 2 2024, 7:30 AM
Unknown Object (File)
Jan 10 2024, 3:42 PM
Unknown Object (File)
Jan 9 2024, 9:07 AM
Unknown Object (File)
Jan 3 2024, 5:51 AM

Details

Summary

This driver add support for the NMI controller for A20 and A31 SoC.
The NMI is mainly used for the PMU.

Test Plan

Apply patch and build kernel and test on hw.

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 Allwinner NMI driver.
manu_bidouilliste.com updated this object.
manu_bidouilliste.com edited the test plan for this revision. (Show Details)
manu_bidouilliste.com added a reviewer: ARM.
manu_bidouilliste.com set the repository for this revision to rS FreeBSD src repository - subversion.
manu_bidouilliste.com added a project: ARM.
jmcneill added inline comments.
sys/arm/allwinner/aw_nmi.c
46 ↗(On Diff #14388)

I think you can include <dt-bindings/interrupt-controller/irq.h> here instead?

sys/arm/allwinner/aw_nmi.c
303 ↗(On Diff #14388)

There's already an '#ifdef ARM_INTRNG' on line 48

I'm sorry but I have changed PIC interface in r297539. It should be stable now and simpler. There are also more controllers rewritten for INTRNG in tree. The BEAGLEBONE aintc.c is a simplest one.

In D5663#125424, @skra wrote:

I'm sorry but I have changed PIC interface in r297539. It should be stable now and simpler. There are also more controllers rewritten for INTRNG in tree. The BEAGLEBONE aintc.c is a simplest one.

No problem :)
I've updated the driver this morning, just need to find some time to test it.

Update diff since INTRNG interface changed.

sys/arm/allwinner/aw_nmi.c
112 ↗(On Diff #15628)

The indentation looks off, it should be tabbed, then 4 spaces.

147 ↗(On Diff #15628)

Is sc used other than to get dev?

sys/arm/allwinner/files.allwinner
13 ↗(On Diff #15628)

You could make this optional intrng and remove the #ifdef INTRNG from aw_nmi.c

Make the driver optional with intrng
Remove some leftover of the convertion
Fix style(9)

andrew added a reviewer: andrew.

The commit should say something like:

Add a driver for the Non-maskable interrupt driver in the Allwinner A20 and A31 SoCs.
This is normally used for the PMU.
sys/arm/allwinner/aw_nmi.c
156–177 ↗(On Diff #15651)

It fells like we could pull this out to a common function (in a future change).

This revision is now accepted and ready to land.Apr 27 2016, 2:16 PM
This revision was automatically updated to reflect the committed changes.