lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZNOCgX8yniu+IuUG@localhost>
Date:   Wed, 9 Aug 2023 20:11:45 +0800
From:   Liang Li <liliang6@...il.cn>
To:     Yicong Yang <yangyicong@...wei.com>
Cc:     Barry Song <21cnbao@...il.com>, Liang Li <liliang6@...il.cn>,
        yangyicong@...ilicon.com, will@...nel.org, mark.rutland@....com,
        linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
        jonathan.cameron@...wei.com, linuxarm@...wei.com
Subject: Re: [PATCH] perf/smmuv3: Add platform id table for module auto
 loading

Hi Yicong,

Thanks for your reply,

On 2023-08-09 14:31, Yicong Yang <yangyicong@...wei.com> wrote:
> Hi Barry, Liang,
> 
> On 2023/8/9 13:47, Barry Song wrote:
> > On Wed, Aug 9, 2023 at 1:01 PM Liang Li <liliang6@...il.cn> wrote:
> >>
> >> On 2023-08-07 20:22, Yicong Yang <yangyicong@...wei.com> wrote:
> >>> From: Yicong Yang <yangyicong@...ilicon.com>
> >>>
> >>> On ACPI based system the device is probed by the name directly. If the
> >>> driver is configured as module it can only be loaded manually. Add the
> >>> platform id table as well as the module alias then the driver will be
> >>> loaded automatically by the udev or others once the device added.
> >>>
> >>
> >> Please consider revise the long log to clearly express the purpose of the
> >> changes in this patch:
> >>
> >> - What's the exact issue the patch is addressing
> >> - Why the changes in this patch can fix the issue or make something working
> >> - Consider impact of the changes introduced by this patch
> >>
> >> These info may help reviewers and maintainers .. and yourself on code merge.
> > 
> > years ago, i found a good doc regarding this,
> > https://wiki.archlinux.org/title/Modalias
> > 
> > guess it is because /lib/modules/$(uname -r)/modules.alias fails to contain smmu
> > driver without the MODULE_DEVICE_TABLE, isn't it, yicong?
> 
> Yes I think it's the reason. I didn't find summary in kernel docs for the modalias
> as well as the uevent mechanism. Arch wiki has a well illustration for the modalias
> and suse[1] describes how this is used by the udev for module auto loading.
> 
> For my case I'm using a ACPI based arm64 server and after booting the arm_smmuv3_pmu.ko
> is not auto loaded by the udevd since we aren't providing this information. In order
> to support this we need to provide this MODULE_DEVICE_TABLE() when the smmu pmu added
> as a platform device, then the userspace udev can know which module to load after the
> device is added.
>

Then what's the purpose of the added '.id_table = ...' line in the previous
patch ?
<We lost the patch context in this thread.>

Based on above clarification, the updated DEVICE_TABLE would update modalias
as expected, right ?

> [1] https://documentation.suse.com/sles/15-SP1/html/SLES-all/cha-udev.html#sec-udev-drivers
> 
> Thanks.

Regards.
Liang Li

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ