Linux-ACPI Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH 0/1 resend] gpiolib: acpi: Add missing __init(const) markers to initcall-s
@ 2020-03-25 10:39 Hans de Goede
  2020-03-25 10:39 ` [PATCH " Hans de Goede
  2020-03-27 21:13 ` [PATCH 0/1 " Linus Walleij
  0 siblings, 2 replies; 3+ messages in thread
From: Hans de Goede @ 2020-03-25 10:39 UTC (permalink / raw)
  To: Mika Westerberg, Andy Shevchenko, Bartosz Golaszewski, Linus Walleij
  Cc: Hans de Goede, linux-gpio, linux-acpi

Hi Linus,

I know it has not been that long ago since I send this out, but still
I have the feeling this one seems to have fallen through the cracks?

It has already been Acked by Mika, so if you can queue it up in
linux-gpio/for-next that would be great.

Regards,

Hans


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH resend] gpiolib: acpi: Add missing __init(const) markers to initcall-s
  2020-03-25 10:39 [PATCH 0/1 resend] gpiolib: acpi: Add missing __init(const) markers to initcall-s Hans de Goede
@ 2020-03-25 10:39 ` " Hans de Goede
  2020-03-27 21:13 ` [PATCH 0/1 " Linus Walleij
  1 sibling, 0 replies; 3+ messages in thread
From: Hans de Goede @ 2020-03-25 10:39 UTC (permalink / raw)
  To: Mika Westerberg, Andy Shevchenko, Bartosz Golaszewski, Linus Walleij
  Cc: Hans de Goede, linux-gpio, linux-acpi

The gpiolib ACPI code uses 2 initcall-s and the called function
(and used DMI table) is missing __init(const) markers.

This commit fixes this freeing up some extra memory once the kernel
has completed booting.

Acked-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 drivers/gpio/gpiolib-acpi.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/gpio/gpiolib-acpi.c b/drivers/gpio/gpiolib-acpi.c
index 0017367e94ee..9276051663da 100644
--- a/drivers/gpio/gpiolib-acpi.c
+++ b/drivers/gpio/gpiolib-acpi.c
@@ -1353,7 +1353,7 @@ int acpi_gpio_count(struct device *dev, const char *con_id)
 }
 
 /* Run deferred acpi_gpiochip_request_irqs() */
-static int acpi_gpio_handle_deferred_request_irqs(void)
+static int __init acpi_gpio_handle_deferred_request_irqs(void)
 {
 	struct acpi_gpio_chip *acpi_gpio, *tmp;
 
@@ -1371,7 +1371,7 @@ static int acpi_gpio_handle_deferred_request_irqs(void)
 /* We must use _sync so that this runs after the first deferred_probe run */
 late_initcall_sync(acpi_gpio_handle_deferred_request_irqs);
 
-static const struct dmi_system_id gpiolib_acpi_quirks[] = {
+static const struct dmi_system_id gpiolib_acpi_quirks[] __initconst = {
 	{
 		/*
 		 * The Minix Neo Z83-4 has a micro-USB-B id-pin handler for
@@ -1455,7 +1455,7 @@ static const struct dmi_system_id gpiolib_acpi_quirks[] = {
 	{} /* Terminating entry */
 };
 
-static int acpi_gpio_setup_params(void)
+static int __init acpi_gpio_setup_params(void)
 {
 	const struct acpi_gpiolib_dmi_quirk *quirk = NULL;
 	const struct dmi_system_id *id;
-- 
2.26.0.rc2


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH 0/1 resend] gpiolib: acpi: Add missing __init(const) markers to initcall-s
  2020-03-25 10:39 [PATCH 0/1 resend] gpiolib: acpi: Add missing __init(const) markers to initcall-s Hans de Goede
  2020-03-25 10:39 ` [PATCH " Hans de Goede
@ 2020-03-27 21:13 ` " Linus Walleij
  1 sibling, 0 replies; 3+ messages in thread
From: Linus Walleij @ 2020-03-27 21:13 UTC (permalink / raw)
  To: Hans de Goede
  Cc: Mika Westerberg, Andy Shevchenko, Bartosz Golaszewski,
	open list:GPIO SUBSYSTEM, ACPI Devel Maling List

On Wed, Mar 25, 2020 at 11:40 AM Hans de Goede <hdegoede@redhat.com> wrote:

> I know it has not been that long ago since I send this out, but still
> I have the feeling this one seems to have fallen through the cracks?
>
> It has already been Acked by Mika, so if you can queue it up in
> linux-gpio/for-next that would be great.

It requires the fixes I just sent to Torvalds to be applied first.
I simply need that stuff to be upstream before I can apply this.
That is why it is deferred.

Sometimes it happens that random fixes are dependent on
critical fixes, then the critical fixes need to land upstream before
the random fix can be applied, this is one of those cases.

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, back to index

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-25 10:39 [PATCH 0/1 resend] gpiolib: acpi: Add missing __init(const) markers to initcall-s Hans de Goede
2020-03-25 10:39 ` [PATCH " Hans de Goede
2020-03-27 21:13 ` [PATCH 0/1 " Linus Walleij

Linux-ACPI Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-acpi/0 linux-acpi/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-acpi linux-acpi/ https://lore.kernel.org/linux-acpi \
		linux-acpi@vger.kernel.org
	public-inbox-index linux-acpi

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-acpi


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git