Page MenuHomeFreeBSD

Allwinner NMI driver
ClosedPublic

Authored by manu_bidouilliste.com on Mar 17 2016, 12:25 PM.
Tags
Referenced Files
Unknown Object (File)
Tue, Dec 3, 3:33 AM
Unknown Object (File)
Sun, Dec 1, 11:55 PM
Unknown Object (File)
Mon, Nov 25, 2:19 PM
Unknown Object (File)
Mon, Nov 25, 11:06 AM
Unknown Object (File)
Sun, Nov 24, 2:28 AM
Unknown Object (File)
Sat, Nov 23, 6:48 PM
Unknown Object (File)
Sat, Nov 23, 1:42 AM
Unknown Object (File)
Fri, Nov 22, 8:02 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.