On Wed, Aug 27, 2025 at 06:51:41PM -0400, Daniel Tang wrote: > Previously, after `rmmod acpi_tad`, `modprobe acpi_tad` would fail > with this dmesg: > > sysfs: cannot create duplicate filename '/devices/platform/ACPI000E:00/time' > Call Trace: > <TASK> > dump_stack_lvl+0x6c/0x90 > dump_stack+0x10/0x20 > sysfs_warn_dup+0x8b/0xa0 > sysfs_add_file_mode_ns+0x122/0x130 > internal_create_group+0x1dd/0x4c0 > sysfs_create_group+0x13/0x20 > acpi_tad_probe+0x147/0x1f0 [acpi_tad] > platform_probe+0x42/0xb0 > </TASK> > acpi-tad ACPI000E:00: probe with driver acpi-tad failed with error -17 > > Fixes: 3230b2b3c1ab5a0d3f99d5850bfdc4bf48d11cdd ("ACPI: TAD: Add low-level support for real time capability") You should shorten this hash to 12 or so chars. Otherwise looks good. > Signed-off-by: Daniel Tang <danielzgtg.opensource@xxxxxxxxx> > --- > drivers/acpi/acpi_tad.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/drivers/acpi/acpi_tad.c b/drivers/acpi/acpi_tad.c > index 91d7d90c47da..33418dd6768a 100644 > --- a/drivers/acpi/acpi_tad.c > +++ b/drivers/acpi/acpi_tad.c > @@ -565,6 +565,9 @@ static void acpi_tad_remove(struct platform_device *pdev) > > pm_runtime_get_sync(dev); > > + if (dd->capabilities & ACPI_TAD_RT) > + sysfs_remove_group(&dev->kobj, &acpi_tad_time_attr_group); > + > if (dd->capabilities & ACPI_TAD_DC_WAKE) > sysfs_remove_group(&dev->kobj, &acpi_tad_dc_attr_group); > > -- > 2.48.1 >