openbouffalo / linux

Linux kernel source tree
Other
6 stars 4 forks source link

Bl808/i2c #12

Open Hunter1753 opened 1 year ago

Hunter1753 commented 1 year ago

This adds support for the BL808 i2c bus.

This driver depends on the pinctrl driver to assign IO pins in the device tree to route out the i2c signals

There are currently two PRs open against the bl808/pinctrl-hwrng (https://github.com/openbouffalo/linux/pull/5 || https://github.com/openbouffalo/linux/pull/6) branch of which one needs to be accepted to be able to correctly route the i2c function to the pins

Danct12 commented 1 year ago

Tested with Sipeed M1s DOCK using a 20x4 I2C Text Screen and lcdproc.

IMG_20230426_200029

Hunter1753 commented 1 year ago

also tested with ssd1306 screen from python

alexhorner commented 1 year ago

Hey Hunter,

It looks like you are in breach of the 80col standard,

Please could you edit your driver to conform to the ouptut of the checkpatch pearl script in the repo?

Also, this is a non-DMA version as far as I remember, right? Would you be happy with this being bl808/i2c-nodma so that we can swap things around as appropriate in the future? There is also the argument that the compatible string could be different for the tree, but that's not something we need to worry about now I don't think. We can think about that later once a DMA version comes around.

Thanks!

Hunter1753 commented 1 year ago

somehow my forcepush closed this PR.

i adressed all but one line for the 80 column limit. also i am fine with the branch being named i2c-nodma for now

Hunter1753 commented 1 year ago

i now adressed all lines for the 80 column limit. checkpatch still reports two errors:

SPLIT_STRING: quoted string split across lines L#230
UNNECESSARY_ELSE: else is not generally useful after a break or return L#586