Re: GSoC IIO project: Mugil

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 3/13/21 7:43 PM, Alexandru Ardelean wrote:
On Sat, Mar 13, 2021 at 5:28 PM Mugilraj <dmugil2000@xxxxxxxxx> wrote:
On Thu, Mar 11, 2021 at 10:58:53AM +0200, Alexandru Ardelean wrote:
On Thu, Mar 11, 2021 at 9:03 AM Mugil Raj <dmugil2000@xxxxxxxxx> wrote:
Hi,
This is Mugilraj, an undergrad at NIT Trichy, India. I'm applying to
GSoC'21 for the project IIO driver. So, I need help from you guys with
the application process and finding the device to develop a driver.
I've done few exercises on patch submissions and completed a Linux
Foundations course, "A beginners guide to Linux kernel development
(LFD103)". I found this "https://kernelnewbies.org/IIO_tasks"; task for
beginners, and now I'm doing that also If anyone suggests some fixes
to develop, that would be helpful for me.


hey,

i posted some ideas here:
https://lore.kernel.org/linux-iio/CA+U=Dsp98caW89g9FbsV-+KQ-NjyOqd+KSkO+aaFp4qBb-hpMg@xxxxxxxxxxxxxx/T/#md6c49f2e457d66d922d3d22f1f6fdb54971e6b8a

[a quick copy + paste from that email]

One thing I've always wanted to do, is to convert the entire IIO
subsystem to devm_ variants.
Essentially getting rid of the iio_device_unregister() function in
favor of using devm_iio_device_unregister() and similar.

There's about ~217 uses of this function.
The more complicated one is in the 'drivers/platform/x86/toshiba_acpi.c'
I think reworking the Toshiba ACPI driver would also be interesting,
but it is some work.

Now, converting everything to devm_ variants can be considered a bit
of an obsession [by some people].
But I sometimes find potential memory leaks by doing this conversion.
And chances are that we may never be able to fully convert the IIO API
to be devm_ variant-only.
But it is an interesting process [for me], just the cleanup itself.
I've gone through docs and I hade a dout on devm_iio_device_register().
If we use this function it  will automatically unregistered on driver
detach. Then what is the use of devm_iio_device_unregister().
[...]
It may be a silly question sorry:).
not a silly question;
this is all kernel API stuff, which isn't obvious in the beginning

Mugil,

There are two drivers that would be good candidates to get started with this, send your first patch and familiarize yourself with the process.

 * drivers/iio/dac/max517.c
 * drivers/iio/gyro/adis16080.c

Basically if iio_device_unregister() is the last function that gets called in the remove() function of the driver it is usually safe to convert the iio_device_register() in the probe function to a devm_iio_device_register().

- Lars




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux