From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Hans de Goede <hdegoede@redhat.com>,
Thierry Reding <thierry.reding@gmail.com>
Cc: linux-pwm@vger.kernel.org,
Mika Westerberg <mika.westerberg@linux.intel.com>
Subject: Re: [PATCH] pwm: lpss-platform: Cleanly exit probe on boards without resources
Date: Fri, 12 Jan 2018 15:04:51 +0200 [thread overview]
Message-ID: <1515762291.7000.947.camel@linux.intel.com> (raw)
In-Reply-To: <20180112113802.3888-1-hdegoede@redhat.com>
+Cc: Mika
On Fri, 2018-01-12 at 12:38 +0100, Hans de Goede wrote:
> Some boards which do not use the pwm-controller have an empty or
> invalid
> resource-table in ACPI the for pwm-controller. Currently this causes
> these
> error messages to get logged:
> [ 3.281966] pwm-lpss 80862288:00: invalid resource
> [ 3.287098] pwm-lpss: probe of 80862288:00 failed with error -22
>
> This commit silences these error messages on these boards by cleanly
> exiting pwm_lpss_probe_platform() if there is no memory resource.
>
I don't see anything wrong with message per se.
> +
> + /*
> + * Some boards which don't use the pwm controller have an
> empty
> + * resources table, so if we cannot get the resource, return
> -ENODEV.
> + */
> r = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> + if (!r)
> + return -ENODEV;
But this one looks like a quirk for some platforms when other can
survive without.
Can we actually check this in acpi_lpss.c and prevent platform device
registration at all?
--
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy
next prev parent reply other threads:[~2018-01-12 13:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-12 11:38 [PATCH] pwm: lpss-platform: Cleanly exit probe on boards without resources Hans de Goede
2018-01-12 13:04 ` Andy Shevchenko [this message]
2018-01-14 19:58 ` Hans de Goede
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1515762291.7000.947.camel@linux.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=hdegoede@redhat.com \
--cc=linux-pwm@vger.kernel.org \
--cc=mika.westerberg@linux.intel.com \
--cc=thierry.reding@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox