Linux Input/HID development
 help / color / mirror / Atom feed
* Re: [PATCH 8/8] docs: remove extra conf.py files
From: Mauro Carvalho Chehab @ 2019-07-15  7:57 UTC (permalink / raw)
  To: Markus Heiser
  Cc: Linux Doc Mailing List, Mauro Carvalho Chehab, linux-kernel,
	Jonathan Corbet, Herbert Xu, David S. Miller, David Airlie,
	Daniel Vetter, Maarten Lankhorst, Maxime Ripard, Sean Paul,
	Dmitry Torokhov, Yoshinori Sato, Rich Felker, Jaroslav Kysela,
	Takashi Iwai, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
	H. Peter Anvin
In-Reply-To: <e3ff0a8a-6956-3855-07be-9c126df2da2d@darmarit.de>

Em Mon, 15 Jul 2019 08:16:54 +0200
Markus Heiser <markus.heiser@darmarit.de> escreveu:

> Hi Mauro,
> 
> sorry, I havn't tested your patch, but one question ...
> 
> Am 14.07.19 um 17:10 schrieb Mauro Carvalho Chehab:
> > Now that the latex_documents are handled automatically, we can
> > remove those extra conf.py files.  
> 
> We need these conf.py also for compiling books' into HTML.  For this
> the tags.add("subproject") is needed.  Should we realy drop this feature?
> 
> -- Markus --

You're right: adding "subproject" tags is needed for html. Folding this
to patch 7/8 makes both htmldocs and pdfdocs to work with SPHINXDIRS
without the need of a per-subdir conf.py.

Regards,
Mauro

diff --git a/Documentation/sphinx/load_config.py b/Documentation/sphinx/load_config.py
index 75f527ff4c95..e4a04f367b41 100644
--- a/Documentation/sphinx/load_config.py
+++ b/Documentation/sphinx/load_config.py
@@ -51,3 +51,7 @@ def loadConfig(namespace):
             execfile_(config_file, config)
             del config['__file__']
             namespace.update(config)
+        else:
+            config = namespace.copy()
+            config['tags'].add("subproject")
+            namespace.update(config)

Thanks,
Mauro

^ permalink raw reply related

* Re: [PATCH v2 2/3] input: touchscreen mc13xxx: Make platform data optional
From: Lukasz Majewski @ 2019-07-15  8:43 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: Lee Jones, linux-kernel, Sascha Hauer, Enrico Weigelt,
	Thomas Gleixner, Kate Stewart, linux-input
In-Reply-To: <20190715071048.GB153485@dtor-ws>

[-- Attachment #1: Type: text/plain, Size: 751 bytes --]

Hi Dmitry,

Thank you for your reply.

> On Fri, Jul 12, 2019 at 12:23:45AM +0200, Lukasz Majewski wrote:
> > From: Sascha Hauer <s.hauer@pengutronix.de>
> > 
> > The platform data once was optional, make it optional again. This
> > is a first step towards device tree support for the mc13xxx
> > touchscreen driver.  
> 
> I would prefer seeing it together with patches introducing device tree
> support.

Ok, I will merge this patch to patch 3/3.

> 
> Thanks.
> 




Best regards,

Lukasz Majewski

--

DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-59 Fax: (+49)-8142-66989-80 Email: lukma@denx.de

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply

* Re: [PATCH v2 3/3] input: touchscreen mc13xxx: Add mc34708 support
From: Lukasz Majewski @ 2019-07-15  9:13 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: Lee Jones, linux-kernel, Sascha Hauer, Enrico Weigelt,
	Thomas Gleixner, Kate Stewart, linux-input
In-Reply-To: <20190715070702.GA153485@dtor-ws>

[-- Attachment #1: Type: text/plain, Size: 4118 bytes --]

Hi Dmitry,

> Hi Lukasz,
>  
> On Fri, Jul 12, 2019 at 12:23:46AM +0200, Lukasz Majewski wrote:
> > From: Sascha Hauer <s.hauer@pengutronix.de>
> > 
> > The mc34708 has a different bit to enable pen detection. This
> > adds the driver data and devtype necessary to probe the device
> > and to distinguish between the mc13783 and the mc34708.
> > 
> > Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> > Signed-off-by: Lukasz Majewski <lukma@denx.de>
> > 
> > ---
> > Changes for v2:
> > - Change nested if statements to a single one (with cr0 > ...)
> > - Replace hardcoded max resistance value (4080) with a generic
> > driver data value.
> > - Introduce new include/linux/mfd/mc34708.h header file for mc34708
> > specific defines
> > - Define as driver data mask and value for accessing mc13xxx
> > registers
> > 
> > Changes from the original patch:
> > - Simplify the mcXXXXX_set_pen_detection functions
> > - Fix checkpatch warnings
> > ---
> >  drivers/input/touchscreen/mc13783_ts.c | 59
> > +++++++++++++++++++++++++++++++--- 1 file changed, 55
> > insertions(+), 4 deletions(-)
> > 
> > diff --git a/drivers/input/touchscreen/mc13783_ts.c
> > b/drivers/input/touchscreen/mc13783_ts.c index
> > edd49e44e0c9..8fd3d0e47f57 100644 ---
> > a/drivers/input/touchscreen/mc13783_ts.c +++
> > b/drivers/input/touchscreen/mc13783_ts.c @@ -10,6 +10,7 @@
> >   */
> >  #include <linux/platform_device.h>
> >  #include <linux/mfd/mc13783.h>
> > +#include <linux/mfd/mc34708.h>
> >  #include <linux/kernel.h>
> >  #include <linux/module.h>
> >  #include <linux/input.h>
> > @@ -30,6 +31,8 @@ MODULE_PARM_DESC(sample_tolerance,
> >  		"is supposed to be wrong and is discarded.  Set to
> > 0 to " "disable this check.");
> >  
> > +struct mc13xxx_driver_data;  
> 
> Why don't you define the structure here instead of sing forward
> declaration? 

I will define the structure here.

> The structure is also commonly called as xxx_chip, so
> struct mc13xxx_chip {
> 	...
> };

Ok.

> 
> > +
> >  struct mc13783_ts_priv {
> >  	struct input_dev *idev;
> >  	struct mc13xxx *mc13xxx;
> > @@ -37,6 +40,33 @@ struct mc13783_ts_priv {
> >  	unsigned int sample[4];
> >  	u8 ato;
> >  	bool atox;
> > +	struct mc13xxx_driver_data *drvdata;  
> 
> const struct mc13xxx_chip *chip;

Ok. I will adjust the name.

> 
> > +};
> > +
> > +enum mc13xxx_type {
> > +	MC13XXX_TYPE_MC13783,
> > +	MC13XXX_TYPE_MC34708,
> > +};
> > +
> > +struct mc13xxx_driver_data {
> > +	enum mc13xxx_type type;
> > +	int max_resistance;
> > +	u32 reg_mask;
> > +	u32 reg_value;
> > +};
> > +
> > +static struct mc13xxx_driver_data mc13783_driver_data = {
> > +	.type = MC13XXX_TYPE_MC13783,
> > 	.max_resistance = 4096,
> > +	.reg_mask = MC13XXX_ADC0_TSMOD_MASK,
> > +	.reg_value = MC13XXX_ADC0_TSMOD0,
> > +};
> > +
> > +static struct mc13xxx_driver_data mc34708_driver_data = {
> > +	.type = MC13XXX_TYPE_MC34708,
> > +	.max_resistance = 4080,
> > +	.reg_mask = MC34708_ADC0_TSMASK,
> > +	.reg_value = MC34708_ADC0_TSPENDETEN,
> >  };  
> 
> Have these 2 closer to the ID table.

I will move those two instances of struct mc13xxx_chip closer to the ID
table.

> 
> >  
> >  static irqreturn_t mc13783_ts_handler(int irq, void *data)
> > @@ -93,6 +123,10 @@ static void mc13783_ts_report_sample(struct
> > mc13783_ts_priv *priv) 
> >  	cr0 = (cr0 + cr1) / 2;
> >  
> > +	if (priv->drvdata->type == MC13XXX_TYPE_MC34708 &&
> > +	    cr0 > priv->drvdata->max_resistance)
> > +		cr0 = 0;  
> 
> I would like to avoid the type comparisons. Given that both cr0 and
> cr1 can't be more than 4095 (because we limit them when parsing
> sampling data) I think we can simply say
> 
> 	if (cr0 > priv->chip->max_resistance)
> 		cr0 = 0;

Ok.

> 
> Thanks.
> 




Best regards,

Lukasz Majewski

--

DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-59 Fax: (+49)-8142-66989-80 Email: lukma@denx.de

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply

* Re: [PATCH v7 1/2] drm/bridge: sil_sii8620: make remote control optional.
From: Dmitry Torokhov @ 2019-07-15 18:04 UTC (permalink / raw)
  To: Life is hard, and then you die
  Cc: Andrzej Hajda, Henrik Rydberg, Andy Shevchenko, Inki Dae,
	Greg Kroah-Hartman, Lukas Wunner, Federico Lorenzi,
	Laurent Pinchart, linux-input, dri-devel, linux-kernel
In-Reply-To: <20190703063956.GA32102@innovation.ch>

Hi,

On Tue, Jul 02, 2019 at 11:39:56PM -0700, Life is hard, and then you die wrote:
> 
> On Tue, Jul 02, 2019 at 03:50:49PM +0200, Andrzej Hajda wrote:
> > On 19.04.2019 10:19, Ronald Tschalär wrote:
> > > commit d6abe6df706c (drm/bridge: sil_sii8620: do not have a dependency
> > > of RC_CORE) changed the driver to select both RC_CORE and INPUT.
> > > However, this causes problems with other drivers, in particular an input
> > > driver that depends on MFD_INTEL_LPSS_PCI (to be added in a separate
> > > commit):
> > > 
> > >   drivers/clk/Kconfig:9:error: recursive dependency detected!
> > >   drivers/clk/Kconfig:9:        symbol COMMON_CLK is selected by MFD_INTEL_LPSS
> > >   drivers/mfd/Kconfig:566:      symbol MFD_INTEL_LPSS is selected by MFD_INTEL_LPSS_PCI
> > >   drivers/mfd/Kconfig:580:      symbol MFD_INTEL_LPSS_PCI is implied by KEYBOARD_APPLESPI
> > >   drivers/input/keyboard/Kconfig:73:    symbol KEYBOARD_APPLESPI depends on INPUT
> > >   drivers/input/Kconfig:8:      symbol INPUT is selected by DRM_SIL_SII8620
> > >   drivers/gpu/drm/bridge/Kconfig:83:    symbol DRM_SIL_SII8620 depends on DRM_BRIDGE
> > >   drivers/gpu/drm/bridge/Kconfig:1:     symbol DRM_BRIDGE is selected by DRM_PL111
> > >   drivers/gpu/drm/pl111/Kconfig:1:      symbol DRM_PL111 depends on COMMON_CLK
> > > 
> > > According to the docs and general consensus, select should only be used
> > > for non user-visible symbols, but both RC_CORE and INPUT are
> > > user-visible. Furthermore almost all other references to INPUT
> > > throughout the kernel config are depends, not selects. For this reason
> > > the first part of this change reverts commit d6abe6df706c.
> > > 
> > > In order to address the original reason for commit d6abe6df706c, namely
> > > that not all boards use the remote controller functionality and hence
> > > should not need have to deal with RC_CORE, the second part of this
> > > change now makes the remote control support in the driver optional and
> > > contingent on RC_CORE being defined. And with this the hard dependency
> > > on INPUT also goes away as that is only needed if RC_CORE is defined
> > > (which in turn already depends on INPUT).
> > > 
> > > CC: Inki Dae <inki.dae@samsung.com>
> > > CC: Andrzej Hajda <a.hajda@samsung.com>
> > > CC: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > CC: Dmitry Torokhov <dmitry.torokhov@gmail.com>
> > > Signed-off-by: Ronald Tschalär <ronald@innovation.ch>
> > > Reviewed-by: Andrzej Hajda <a.hajda@samsung.com>
> > 
> > 
> > Apparently this patch was not queued to kernel yet. If there are no
> > objections I will queue it via drm-misc-next tree tomorrow.
> 
> If this patch set won't be queued for 5.3 then I guess that would be a
> good idea.
> 
> But may I ask what is preventing this patch set from being queued for
> upstream, so I can try and fix whatever the issue is?

As I mentioned in my pull request to Linux I will be picking up the
Apple keyboard driver for this merge window even though it was not in
next (my fault).

I created and immutable branch for this change if you'd like to pull it
in so we do not duplicate commit and risk the conflicts (but I believe
git should resolve it either way).

https://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git id/5.2-sil_sii8620-rc-optional

Thanks.

-- 
Dmitry

^ permalink raw reply

* Re: [PATCH v2 2/3] input: touchscreen mc13xxx: Make platform data optional
From: Dmitry Torokhov @ 2019-07-15 18:27 UTC (permalink / raw)
  To: Lukasz Majewski
  Cc: Lee Jones, linux-kernel, Sascha Hauer, Enrico Weigelt,
	Thomas Gleixner, Kate Stewart, linux-input
In-Reply-To: <20190715104344.3f17b660@jawa>

On Mon, Jul 15, 2019 at 10:43:44AM +0200, Lukasz Majewski wrote:
> Hi Dmitry,
> 
> Thank you for your reply.
> 
> > On Fri, Jul 12, 2019 at 12:23:45AM +0200, Lukasz Majewski wrote:
> > > From: Sascha Hauer <s.hauer@pengutronix.de>
> > > 
> > > The platform data once was optional, make it optional again. This
> > > is a first step towards device tree support for the mc13xxx
> > > touchscreen driver.  
> > 
> > I would prefer seeing it together with patches introducing device tree
> > support.
> 
> Ok, I will merge this patch to patch 3/3.

Uh, I must be missing something, but I do not see anything dedicated to
device tree handling in 3/3...

Thanks.

-- 
Dmitry

^ permalink raw reply

* Re: [PATCH v7 1/2] drm/bridge: sil_sii8620: make remote control optional.
From: Dmitry Torokhov @ 2019-07-15 20:00 UTC (permalink / raw)
  To: Life is hard, and then you die
  Cc: Andrzej Hajda, Henrik Rydberg, Andy Shevchenko, Inki Dae,
	Greg Kroah-Hartman, Lukas Wunner, Federico Lorenzi,
	Laurent Pinchart, linux-input@vger.kernel.org, DRI, lkml
In-Reply-To: <20190715180407.GB131063@dtor-ws>

On Mon, Jul 15, 2019 at 11:04 AM Dmitry Torokhov
<dmitry.torokhov@gmail.com> wrote:
>
> Hi,
>
> On Tue, Jul 02, 2019 at 11:39:56PM -0700, Life is hard, and then you die wrote:
> >
> > On Tue, Jul 02, 2019 at 03:50:49PM +0200, Andrzej Hajda wrote:
> > > On 19.04.2019 10:19, Ronald Tschalär wrote:
> > > > commit d6abe6df706c (drm/bridge: sil_sii8620: do not have a dependency
> > > > of RC_CORE) changed the driver to select both RC_CORE and INPUT.
> > > > However, this causes problems with other drivers, in particular an input
> > > > driver that depends on MFD_INTEL_LPSS_PCI (to be added in a separate
> > > > commit):
> > > >
> > > >   drivers/clk/Kconfig:9:error: recursive dependency detected!
> > > >   drivers/clk/Kconfig:9:        symbol COMMON_CLK is selected by MFD_INTEL_LPSS
> > > >   drivers/mfd/Kconfig:566:      symbol MFD_INTEL_LPSS is selected by MFD_INTEL_LPSS_PCI
> > > >   drivers/mfd/Kconfig:580:      symbol MFD_INTEL_LPSS_PCI is implied by KEYBOARD_APPLESPI
> > > >   drivers/input/keyboard/Kconfig:73:    symbol KEYBOARD_APPLESPI depends on INPUT
> > > >   drivers/input/Kconfig:8:      symbol INPUT is selected by DRM_SIL_SII8620
> > > >   drivers/gpu/drm/bridge/Kconfig:83:    symbol DRM_SIL_SII8620 depends on DRM_BRIDGE
> > > >   drivers/gpu/drm/bridge/Kconfig:1:     symbol DRM_BRIDGE is selected by DRM_PL111
> > > >   drivers/gpu/drm/pl111/Kconfig:1:      symbol DRM_PL111 depends on COMMON_CLK
> > > >
> > > > According to the docs and general consensus, select should only be used
> > > > for non user-visible symbols, but both RC_CORE and INPUT are
> > > > user-visible. Furthermore almost all other references to INPUT
> > > > throughout the kernel config are depends, not selects. For this reason
> > > > the first part of this change reverts commit d6abe6df706c.
> > > >
> > > > In order to address the original reason for commit d6abe6df706c, namely
> > > > that not all boards use the remote controller functionality and hence
> > > > should not need have to deal with RC_CORE, the second part of this
> > > > change now makes the remote control support in the driver optional and
> > > > contingent on RC_CORE being defined. And with this the hard dependency
> > > > on INPUT also goes away as that is only needed if RC_CORE is defined
> > > > (which in turn already depends on INPUT).
> > > >
> > > > CC: Inki Dae <inki.dae@samsung.com>
> > > > CC: Andrzej Hajda <a.hajda@samsung.com>
> > > > CC: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > > CC: Dmitry Torokhov <dmitry.torokhov@gmail.com>
> > > > Signed-off-by: Ronald Tschalär <ronald@innovation.ch>
> > > > Reviewed-by: Andrzej Hajda <a.hajda@samsung.com>
> > >
> > >
> > > Apparently this patch was not queued to kernel yet. If there are no
> > > objections I will queue it via drm-misc-next tree tomorrow.
> >
> > If this patch set won't be queued for 5.3 then I guess that would be a
> > good idea.
> >
> > But may I ask what is preventing this patch set from being queued for
> > upstream, so I can try and fix whatever the issue is?
>
> As I mentioned in my pull request to Linux I will be picking up the
> Apple keyboard driver for this merge window even though it was not in
> next (my fault).
>
> I created and immutable branch for this change if you'd like to pull it
> in so we do not duplicate commit and risk the conflicts (but I believe
> git should resolve it either way).
>
> https://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git id/5.2-sil_sii8620-rc-optional

Sorry, that should have read:

https://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git
ib/5.2-sil_sii8620-rc-optional

Thanks.

-- 
Dmitry

^ permalink raw reply

* [PATCH] Input: psmouse - Fix build error of multiple definition
From: YueHaibing @ 2019-07-16  6:54 UTC (permalink / raw)
  To: dmitry.torokhov, allison, tglx, info, dilinger
  Cc: linux-kernel, linux-input, YueHaibing

trackpoint_detect() should be static inline while
CONFIG_MOUSE_PS2_TRACKPOINT is not set. otherwire,we
got building fails:

drivers/input/mouse/alps.o: In function `trackpoint_detect':
alps.c:(.text+0x8e00): multiple definition of `trackpoint_detect'
drivers/input/mouse/psmouse-base.o:psmouse-base.c:(.text+0x1b50): first defined here

Reported-by: Hulk Robot <hulkci@huawei.com>
Fixes: 55e3d9224b60 ("Input: psmouse - allow disabing certain protocol extensions")
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/input/mouse/trackpoint.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/input/mouse/trackpoint.h b/drivers/input/mouse/trackpoint.h
index 0afffe8..77110f3 100644
--- a/drivers/input/mouse/trackpoint.h
+++ b/drivers/input/mouse/trackpoint.h
@@ -158,7 +158,8 @@ struct trackpoint_data {
 #ifdef CONFIG_MOUSE_PS2_TRACKPOINT
 int trackpoint_detect(struct psmouse *psmouse, bool set_properties);
 #else
-inline int trackpoint_detect(struct psmouse *psmouse, bool set_properties)
+static inline int trackpoint_detect(struct psmouse *psmouse,
+				    bool set_properties)
 {
 	return -ENOSYS;
 }
-- 
2.7.4

^ permalink raw reply related

* Re: [PATCH v2 2/3] input: touchscreen mc13xxx: Make platform data optional
From: Lukasz Majewski @ 2019-07-16  7:02 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: Lee Jones, linux-kernel, Sascha Hauer, Enrico Weigelt,
	Thomas Gleixner, Kate Stewart, linux-input
In-Reply-To: <20190715182757.GA136092@dtor-ws>

[-- Attachment #1: Type: text/plain, Size: 1265 bytes --]

Hi Dmitry,

> On Mon, Jul 15, 2019 at 10:43:44AM +0200, Lukasz Majewski wrote:
> > Hi Dmitry,
> > 
> > Thank you for your reply.
> >   
> > > On Fri, Jul 12, 2019 at 12:23:45AM +0200, Lukasz Majewski wrote:  
> > > > From: Sascha Hauer <s.hauer@pengutronix.de>
> > > > 
> > > > The platform data once was optional, make it optional again.
> > > > This is a first step towards device tree support for the mc13xxx
> > > > touchscreen driver.    
> > > 
> > > I would prefer seeing it together with patches introducing device
> > > tree support.  
> > 
> > Ok, I will merge this patch to patch 3/3.  
> 
> Uh, I must be missing something, but I do not see anything dedicated
> to device tree handling in 3/3...

Yes, you are right - the 3/3 adds only IDs for mc34708 device.

The device tree conversion/handling is not planned for now.

Patches, which I've sent in this series, allow the mc34708 device to be
usable with contemporary kernel (e.g. 5.2).

> 
> Thanks.
> 




Best regards,

Lukasz Majewski

--

DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-59 Fax: (+49)-8142-66989-80 Email: lukma@denx.de

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply

* Re: [PATCH v2 2/2] input: soc_button_array for newer surface devices
From: Dmitry Torokhov @ 2019-07-16  7:21 UTC (permalink / raw)
  To: Maximilian Luz
  Cc: linux-kernel, linux-input, platform-driver-x86, Hans de Goede,
	Chen Yu, Darren Hart, Andy Shevchenko, Benjamin Tissoires
In-Reply-To: <20190702003740.75970-3-luzmaximilian@gmail.com>

Hi Maximilian,

On Tue, Jul 02, 2019 at 02:37:40AM +0200, Maximilian Luz wrote:
> Power and volume button support for 5th and 6th genration Microsoft
> Surface devices via soc_button_array.
> 
> Note that these devices use the same MSHW0040 device as on the Surface
> Pro 4, however the implementation is different (GPIOs vs. ACPI
> notifications). Thus some checking is required to ensure we only load
> this driver on the correct devices.

When you are saying that Pro 4 and later models use different
notifications, does this mean that Pro 4 does not define any GPIOs? If
so can we use their presence as indicator whether we should be using
this driver or not. I would like to avoid repeating the ACPI parsing
code that you have in the platform driver.

> +static int soc_device_check_MSHW0040(struct device *dev)
> +{
> +	acpi_handle handle = ACPI_HANDLE(dev);
> +	union acpi_object *result;
> +	u64 oem_platform_rev = 0;
> +	int gpios;
> +
> +	// get OEM platform revision
> +	result = acpi_evaluate_dsm_typed(handle, &MSHW0040_DSM_UUID,
> +					 MSHW0040_DSM_REVISION,
> +					 MSHW0040_DSM_GET_OMPR, NULL,
> +					 ACPI_TYPE_INTEGER);
> +
> +	if (result) {
> +		oem_platform_rev = result->integer.value;
> +		ACPI_FREE(result);
> +	}
> +
> +	if (oem_platform_rev == 0)
> +		return -ENODEV;
> +
> +	dev_dbg(dev, "OEM Platform Revision %llu\n", oem_platform_rev);
> +
> +	/*
> +	 * We are _really_ expecting GPIOs here. If we do not get any, this
> +	 * means the GPIO driver has not been loaded yet (which can happen).
> +	 * Try again later.
> +	 */
> +	gpios = gpiod_count(dev, NULL);
> +	if (gpios < 0)
> +		return -EAGAIN;

I do not believe -EAGAIN has any special meaning in the driver core;
also when the GPIO controller is not ready gpiod_get() will return
-EPROBE_DEFER, which is the prober way if signalling that some resource
is not yet available and probe should be retries at a later time.

Moreover, I do not believe that gpiod_count() needs GPIO controller to
be ready, the count is taken from board firmware or static board file
definition, so if gpiod_count() returns 0 it should be clear indication
that the driver should not be used with the device.

Thanks.

-- 
Dmitry

^ permalink raw reply

* Re: [PATCH 1/5] Input: fsl-imx25-tcq: Use devm_platform_ioremap_resource()
From: Dmitry Torokhov @ 2019-07-16  7:30 UTC (permalink / raw)
  To: Mukesh Ojha
  Cc: s.hauer, linux-kernel, linux-imx, linux-input, shawnguo,
	linux-arm-kernel
In-Reply-To: <1554362243-2888-2-git-send-email-mojha@codeaurora.org>

On Thu, Apr 04, 2019 at 12:47:19PM +0530, Mukesh Ojha wrote:
> devm_platform_ioremap_resource() internally have platform_get_resource()
> and devm_ioremap_resource() in it. So instead of calling them separately
> use devm_platform_ioremap_resource() directly.
> 
> Signed-off-by: Mukesh Ojha <mojha@codeaurora.org>

Applied, thank you.

> ---
>  drivers/input/touchscreen/fsl-imx25-tcq.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/input/touchscreen/fsl-imx25-tcq.c b/drivers/input/touchscreen/fsl-imx25-tcq.c
> index 1d6c8f4..b66df8a 100644
> --- a/drivers/input/touchscreen/fsl-imx25-tcq.c
> +++ b/drivers/input/touchscreen/fsl-imx25-tcq.c
> @@ -503,7 +503,6 @@ static int mx25_tcq_probe(struct platform_device *pdev)
>  	struct input_dev *idev;
>  	struct mx25_tcq_priv *priv;
>  	struct mx25_tsadc *tsadc = dev_get_drvdata(dev->parent);
> -	struct resource *res;
>  	void __iomem *mem;
>  	int error;
>  
> @@ -512,8 +511,7 @@ static int mx25_tcq_probe(struct platform_device *pdev)
>  		return -ENOMEM;
>  	priv->dev = dev;
>  
> -	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	mem = devm_ioremap_resource(dev, res);
> +	mem = devm_platform_ioremap_resource(pdev, 0);
>  	if (IS_ERR(mem))
>  		return PTR_ERR(mem);
>  
> -- 
> Qualcomm India Private Limited, on behalf of Qualcomm Innovation Center,
> Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
> 

-- 
Dmitry

^ permalink raw reply

* Re: [PATCH 2/5] Input: mxs-lradc-ts.c: Use devm_platform_ioremap_resource()
From: Dmitry Torokhov @ 2019-07-16  7:32 UTC (permalink / raw)
  To: Mukesh Ojha
  Cc: shawnguo, s.hauer, linux-imx, linux-input, linux-arm-kernel,
	linux-kernel
In-Reply-To: <1554362243-2888-3-git-send-email-mojha@codeaurora.org>

On Thu, Apr 04, 2019 at 12:47:20PM +0530, Mukesh Ojha wrote:
> devm_platform_ioremap_resource() internally have platform_get_resource()
> and devm_ioremap_resource() in it. So instead of calling them separately
> use devm_platform_ioremap_resource() directly.
> 
> Signed-off-by: Mukesh Ojha <mojha@codeaurora.org>
> ---
>  drivers/input/touchscreen/mxs-lradc-ts.c | 6 +-----
>  1 file changed, 1 insertion(+), 5 deletions(-)
> 
> diff --git a/drivers/input/touchscreen/mxs-lradc-ts.c b/drivers/input/touchscreen/mxs-lradc-ts.c
> index c850b51..af047fa 100644
> --- a/drivers/input/touchscreen/mxs-lradc-ts.c
> +++ b/drivers/input/touchscreen/mxs-lradc-ts.c
> @@ -615,7 +615,6 @@ static int mxs_lradc_ts_probe(struct platform_device *pdev)
>  	struct device_node *node = dev->parent->of_node;
>  	struct mxs_lradc *lradc = dev_get_drvdata(dev->parent);
>  	struct mxs_lradc_ts *ts;
> -	struct resource *iores;
>  	int ret, irq, virq, i;
>  	u32 ts_wires = 0, adapt;
>  
> @@ -629,10 +628,7 @@ static int mxs_lradc_ts_probe(struct platform_device *pdev)
>  	ts->dev = dev;
>  	spin_lock_init(&ts->lock);
>  
> -	iores = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	if (!iores)
> -		return -EINVAL;
> -	ts->base = devm_ioremap(dev, iores->start, resource_size(iores));
> +	ts->base = devm_platform_ioremap_resource(pdev, 0);
>  	if (!ts->base)
>  		return -ENOMEM;

This driver did not implement error handling properly (should have used
IS_ERR()/PTR_ERR()), I adjusted and applied.

Thanks.

-- 
Dmitry

^ permalink raw reply

* Re: [PATCH 4/5] Input: sun4i-ts: Use devm_platform_ioremap_resource()
From: Dmitry Torokhov @ 2019-07-16  7:34 UTC (permalink / raw)
  To: Mukesh Ojha
  Cc: shawnguo, s.hauer, linux-imx, linux-input, linux-arm-kernel,
	linux-kernel
In-Reply-To: <1554362243-2888-5-git-send-email-mojha@codeaurora.org>

On Thu, Apr 04, 2019 at 12:47:22PM +0530, Mukesh Ojha wrote:
> devm_platform_ioremap_resource() internally have platform_get_resource()
> and devm_ioremap_resource() in it. So instead of calling them separately
> use devm_platform_ioremap_resource() directly.
> 
> Signed-off-by: Mukesh Ojha <mojha@codeaurora.org>

Applied, thank you.

> ---
>  drivers/input/touchscreen/sun4i-ts.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/input/touchscreen/sun4i-ts.c b/drivers/input/touchscreen/sun4i-ts.c
> index d2e14d9..bbb0104 100644
> --- a/drivers/input/touchscreen/sun4i-ts.c
> +++ b/drivers/input/touchscreen/sun4i-ts.c
> @@ -309,8 +309,7 @@ static int sun4i_ts_probe(struct platform_device *pdev)
>  		input_set_drvdata(ts->input, ts);
>  	}
>  
> -	ts->base = devm_ioremap_resource(dev,
> -			      platform_get_resource(pdev, IORESOURCE_MEM, 0));
> +	ts->base = devm_platform_ioremap_resource(pdev, 0);
>  	if (IS_ERR(ts->base))
>  		return PTR_ERR(ts->base);
>  
> -- 
> Qualcomm India Private Limited, on behalf of Qualcomm Innovation Center,
> Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
> 

-- 
Dmitry

^ permalink raw reply

* Re: [PATCH 5/5] Input: ts4800-ts: Use devm_platform_ioremap_resource()
From: Dmitry Torokhov @ 2019-07-16  7:34 UTC (permalink / raw)
  To: Mukesh Ojha
  Cc: shawnguo, s.hauer, linux-imx, linux-input, linux-arm-kernel,
	linux-kernel
In-Reply-To: <1554362243-2888-6-git-send-email-mojha@codeaurora.org>

On Thu, Apr 04, 2019 at 12:47:23PM +0530, Mukesh Ojha wrote:
> devm_platform_ioremap_resource() internally have platform_get_resource()
> and devm_ioremap_resource() in it. So instead of calling them separately
> use devm_platform_ioremap_resource() directly.
> 
> Signed-off-by: Mukesh Ojha <mojha@codeaurora.org>

Applied, thank you.

> ---
>  drivers/input/touchscreen/ts4800-ts.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/input/touchscreen/ts4800-ts.c b/drivers/input/touchscreen/ts4800-ts.c
> index fed73ee..5b4f536 100644
> --- a/drivers/input/touchscreen/ts4800-ts.c
> +++ b/drivers/input/touchscreen/ts4800-ts.c
> @@ -148,7 +148,6 @@ static int ts4800_ts_probe(struct platform_device *pdev)
>  {
>  	struct input_polled_dev *poll_dev;
>  	struct ts4800_ts *ts;
> -	struct resource *res;
>  	int error;
>  
>  	ts = devm_kzalloc(&pdev->dev, sizeof(*ts), GFP_KERNEL);
> @@ -159,8 +158,7 @@ static int ts4800_ts_probe(struct platform_device *pdev)
>  	if (error)
>  		return error;
>  
> -	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	ts->base = devm_ioremap_resource(&pdev->dev, res);
> +	ts->base = devm_platform_ioremap_resource(pdev, 0);
>  	if (IS_ERR(ts->base))
>  		return PTR_ERR(ts->base);
>  
> -- 
> Qualcomm India Private Limited, on behalf of Qualcomm Innovation Center,
> Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
> 

-- 
Dmitry

^ permalink raw reply

* [PATCH] hid-logitech-dj: rename "gaming" receiver to "lightspeed"
From: Filipe Laíns @ 2019-07-16  7:36 UTC (permalink / raw)
  Cc: nlopezcasad, Filipe Laíns, Jiri Kosina, Benjamin Tissoires,
	linux-input, linux-kernel

this should help people identify the receiver. there are several
receivers used in gaming mice. the "lightspeed" technology is pretty
well advertise so this won't just be an obscure name.

Signed-off-by: Filipe Laíns <lains@archlinux.org>
---
 drivers/hid/hid-ids.h         | 2 +-
 drivers/hid/hid-logitech-dj.c | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h
index 0d695f8e1b2c..ab9d382b067d 100644
--- a/drivers/hid/hid-ids.h
+++ b/drivers/hid/hid-ids.h
@@ -768,7 +768,7 @@
 #define USB_DEVICE_ID_LOGITECH_NANO_RECEIVER		0xc52f
 #define USB_DEVICE_ID_LOGITECH_UNIFYING_RECEIVER_2	0xc532
 #define USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_2		0xc534
-#define USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_GAMING	0xc539
+#define USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_LIGHTSPEED	0xc539
 #define USB_DEVICE_ID_SPACETRAVELLER	0xc623
 #define USB_DEVICE_ID_SPACENAVIGATOR	0xc626
 #define USB_DEVICE_ID_DINOVO_DESKTOP	0xc704
diff --git a/drivers/hid/hid-logitech-dj.c b/drivers/hid/hid-logitech-dj.c
index 6196217a7d93..4334acb49129 100644
--- a/drivers/hid/hid-logitech-dj.c
+++ b/drivers/hid/hid-logitech-dj.c
@@ -1832,9 +1832,9 @@ static const struct hid_device_id logi_dj_receivers[] = {
 	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH,
 			 USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_2),
 	 .driver_data = recvr_type_hidpp},
-	{ /* Logitech gaming receiver (0xc539) */
+	{ /* Logitech lightspeed receiver (0xc539) */
 	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH,
-		USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_GAMING),
+		USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_LIGHTSPEED),
 	 .driver_data = recvr_type_gaming_hidpp},
 	{ /* Logitech 27 MHz HID++ 1.0 receiver (0xc513) */
 	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_MX3000_RECEIVER),
-- 
2.22.0

^ permalink raw reply related

* [PATCH] hid-logitech-hidpp: add USB PID for some mice
From: Filipe Laíns @ 2019-07-16  7:37 UTC (permalink / raw)
  Cc: nlopezcasad, Filipe Laíns, Jiri Kosina, Benjamin Tissoires,
	linux-input, linux-kernel

Signed-off-by: Filipe Laíns <lains@archlinux.org>
---
 drivers/hid/hid-logitech-hidpp.c | 32 +++++++++++++++++++++++++++++++-
 1 file changed, 31 insertions(+), 1 deletion(-)

diff --git a/drivers/hid/hid-logitech-hidpp.c b/drivers/hid/hid-logitech-hidpp.c
index e3b6245bf4b2..21268c9fa71a 100644
--- a/drivers/hid/hid-logitech-hidpp.c
+++ b/drivers/hid/hid-logitech-hidpp.c
@@ -3749,15 +3749,45 @@ static const struct hid_device_id hidpp_devices[] = {
 
 	{ L27MHZ_DEVICE(HID_ANY_ID) },
 
-	{ /* Logitech G403 Gaming Mouse over USB */
+	{ /* Logitech G203/Prodigy Gaming Mouse */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC084) },
+	{ /* Logitech G302 Gaming Mouse */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC07F) },
+	{ /* Logitech G303 Gaming Mouse */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC080) },
+	{ /* Logitech G400 Gaming Mouse */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC07E) },
+	{ /* Logitech G403 Wireless Gaming Mouse over USB */
 	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC082) },
+	{ /* Logitech G403 Gaming Mouse */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC083) },
+	{ /* Logitech G403 Hero Gaming Mouse over USB */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC08F) },
+	{ /* Logitech G502 Proteus Core Gaming Mouse */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC07D) },
+	{ /* Logitech G502 Proteus Spectrum Gaming Mouse over USB */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC332) },
+	{ /* Logitech G502 Hero Gaming Mouse over USB */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC08B) },
 	{ /* Logitech G700 Gaming Mouse over USB */
 	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC06B) },
+	{ /* Logitech G700s Gaming Mouse over USB */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC07C) },
+	{ /* Logitech G703 Gaming Mouse over USB */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC087) },
+	{ /* Logitech G703 Hero Gaming Mouse over USB */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC090) },
 	{ /* Logitech G900 Gaming Mouse over USB */
 	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC081) },
+	{ /* Logitech G903 Gaming Mouse over USB */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC086) },
+	{ /* Logitech G903 Hero Gaming Mouse over USB */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC091) },
 	{ /* Logitech G920 Wheel over USB */
 	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_G920_WHEEL),
 		.driver_data = HIDPP_QUIRK_CLASS_G920 | HIDPP_QUIRK_FORCE_OUTPUT_REPORTS},
+	{ /* Logitech G Pro Gaming Mouse over USB */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, 0xC088) },
 
 	{ /* MX5000 keyboard over Bluetooth */
 	  HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_LOGITECH, 0xb305),
-- 
2.22.0

^ permalink raw reply related

* [PATCH] hid-logitech-dj: add the Powerplay receiver
From: Filipe Laíns @ 2019-07-16  7:37 UTC (permalink / raw)
  Cc: nlopezcasad, Filipe Laíns, Jiri Kosina, Benjamin Tissoires,
	linux-input, linux-kernel

Signed-off-by: Filipe Laíns <lains@archlinux.org>
---
 drivers/hid/hid-ids.h         | 1 +
 drivers/hid/hid-logitech-dj.c | 4 ++++
 2 files changed, 5 insertions(+)

diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h
index ab9d382b067d..884356feb016 100644
--- a/drivers/hid/hid-ids.h
+++ b/drivers/hid/hid-ids.h
@@ -769,6 +769,7 @@
 #define USB_DEVICE_ID_LOGITECH_UNIFYING_RECEIVER_2	0xc532
 #define USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_2		0xc534
 #define USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_LIGHTSPEED	0xc539
+#define USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_POWERPLAY	0xc53a
 #define USB_DEVICE_ID_SPACETRAVELLER	0xc623
 #define USB_DEVICE_ID_SPACENAVIGATOR	0xc626
 #define USB_DEVICE_ID_DINOVO_DESKTOP	0xc704
diff --git a/drivers/hid/hid-logitech-dj.c b/drivers/hid/hid-logitech-dj.c
index 4334acb49129..d5b47ec1510c 100644
--- a/drivers/hid/hid-logitech-dj.c
+++ b/drivers/hid/hid-logitech-dj.c
@@ -1839,6 +1839,10 @@ static const struct hid_device_id logi_dj_receivers[] = {
 	{ /* Logitech 27 MHz HID++ 1.0 receiver (0xc513) */
 	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_MX3000_RECEIVER),
 	 .driver_data = recvr_type_27mhz},
+	{ /* Logitech powerplay receiver (0xc53a) */
+	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH,
+		USB_DEVICE_ID_LOGITECH_NANO_RECEIVER_POWERPLAY),
+	 .driver_data = recvr_type_gaming_hidpp},
 	{ /* Logitech 27 MHz HID++ 1.0 receiver (0xc517) */
 	  HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH,
 		USB_DEVICE_ID_S510_RECEIVER_2),
-- 
2.22.0

^ permalink raw reply related

* Re: [PATCH 3/5] Input: s3c2410_ts: Use devm_platform_ioremap_resource()
From: Dmitry Torokhov @ 2019-07-16  7:39 UTC (permalink / raw)
  To: Mukesh Ojha
  Cc: shawnguo, s.hauer, linux-imx, linux-input, linux-arm-kernel,
	linux-kernel
In-Reply-To: <1554362243-2888-4-git-send-email-mojha@codeaurora.org>

Hi Mukesh,

On Thu, Apr 04, 2019 at 12:47:21PM +0530, Mukesh Ojha wrote:
> devm_platform_ioremap_resource() internally have platform_get_resource()
> and devm_ioremap_resource() in it. So instead of calling them separately
> use devm_platform_ioremap_resource() directly.
> 
> Signed-off-by: Mukesh Ojha <mojha@codeaurora.org>
> ---
>  drivers/input/touchscreen/s3c2410_ts.c | 10 +---------
>  1 file changed, 1 insertion(+), 9 deletions(-)
> 
> diff --git a/drivers/input/touchscreen/s3c2410_ts.c b/drivers/input/touchscreen/s3c2410_ts.c
> index 1173890..e11cdae 100644
> --- a/drivers/input/touchscreen/s3c2410_ts.c
> +++ b/drivers/input/touchscreen/s3c2410_ts.c
> @@ -242,7 +242,6 @@ static int s3c2410ts_probe(struct platform_device *pdev)
>  	struct s3c2410_ts_mach_info *info;
>  	struct device *dev = &pdev->dev;
>  	struct input_dev *input_dev;
> -	struct resource *res;
>  	int ret = -EINVAL;
>  
>  	/* Initialise input stuff */
> @@ -277,14 +276,7 @@ static int s3c2410ts_probe(struct platform_device *pdev)
>  		goto err_clk;
>  	}
>  
> -	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	if (!res) {
> -		dev_err(dev, "no resource for registers\n");
> -		ret = -ENOENT;
> -		goto err_clk;
> -	}
> -
> -	ts.io = ioremap(res->start, resource_size(res));
> +	ts.io = devm_platform_ioremap_resource(pdev, 0);

This is not an equivalent transformation: the original code (rightly or
wrongly) did not request the memory regions described by 'res' while new
variant does.

Also you can't simply slap a single devm resource in a driver that does
not use managed resources as it messes up the release order.

-- 
Dmitry

^ permalink raw reply

* [PATCH -next] keyboard: remove set but not used variables 'sts'
From: Mao Wenan @ 2019-07-16  8:54 UTC (permalink / raw)
  To: dmitry.torokhov; +Cc: linux-input, linux-kernel, kernel-janitors, Mao Wenan

Fixes gcc '-Wunused-but-set-variable' warning:

drivers/input/keyboard/applespi.c: In function applespi_set_bl_level:
drivers/input/keyboard/applespi.c:902:6: warning: variable sts set but not used [-Wunused-but-set-variable]

Fixes: b426ac0452093d ("Input: add Apple SPI keyboard and trackpad driver")

Signed-off-by: Mao Wenan <maowenan@huawei.com>
---
 drivers/input/keyboard/applespi.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/input/keyboard/applespi.c b/drivers/input/keyboard/applespi.c
index c1a6843..548737e 100644
--- a/drivers/input/keyboard/applespi.c
+++ b/drivers/input/keyboard/applespi.c
@@ -899,7 +899,6 @@ static void applespi_set_bl_level(struct led_classdev *led_cdev,
 	struct applespi_data *applespi =
 		container_of(led_cdev, struct applespi_data, backlight_info);
 	unsigned long flags;
-	int sts;
 
 	spin_lock_irqsave(&applespi->cmd_msg_lock, flags);
 
@@ -916,7 +915,7 @@ static void applespi_set_bl_level(struct led_classdev *led_cdev,
 			 KBD_BL_LEVEL_MIN);
 	}
 
-	sts = applespi_send_cmd_msg(applespi);
+	applespi_send_cmd_msg(applespi);
 
 	spin_unlock_irqrestore(&applespi->cmd_msg_lock, flags);
 }
-- 
2.7.4

^ permalink raw reply related

* [PATCH 00/14] pending doc patches for 5.3-rc
From: Mauro Carvalho Chehab @ 2019-07-16 12:10 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, linux-scsi, esc.storagedev, linuxppc-dev,
	Jonathan Corbet, alsa-devel, kvm, linux-i2c, rcu, linux-pm,
	linux-doc, devicetree, linux-arch, linux-arm-kernel,
	linux-watchdog, x86, dri-devel, netdev, linux-crypto, linux-sh,
	linux-input, linux-pci

Those are the pending documentation patches after my pull request
for this branch:

    git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media.git tags/docs/v5.3-1

Patches 1 to 13 were already submitted, but got rebased. Patch 14
is a new fixup one.

Patches 1 and 2 weren't submitted before due to merge conflicts
that are now solved upstream;

Patch 3 fixes a series of random Documentation/* references that
are pointing to the wrong places.

Patch 4 fix a longstanding issue: every time a new book is added,
conf.py need changes, in order to allow generating a PDF file.
After the patch, conf.py will automatically recognize new books,
saving the trouble of keeping adding documents to it.

Patches 5 to 11 are due to fonts support when building translations.pdf.
The main focus is to add xeCJK support. While doing it, I discovered
some bugs at sphinx-pre-install script after running it with 7 different
distributions.

Patch 12 improves support for partial doc building. Currently, each
subdir needs to have its own conf.py, in order to support partial
doc build. After it, any Documentation subdir can be used to 
roduce html/pdf docs with:

	make SPHINXDIRS="foo bar" htmldocs
	(or pdfdocs, latexdocs, epubdocs, ...)

Patch 13 is a cleanup patch: it simply get rid of all those extra
conf.py files that  aren't needed anymore. The only extra config
file after it is this one:

	Documentation/media/conf_nitpick.py

With enables some extra optional Sphinx features.

Patch 14 adds Documentation/virtual to the main index.rst file
and add a new *.rst file that was orphaned there.

-

After this series, there's just one more patch meant to be applied
for 5.3, with is still waiting for some patches to be merged from
linux-next:

    https://git.linuxtv.org/mchehab/experimental.git/commit/?id=b1b5dc7d7bbfbbfdace2a248c6458301c6e34100


Mauro Carvalho Chehab (14):
  docs: powerpc: convert docs to ReST and rename to *.rst
  docs: power: add it to to the main documentation index
  docs: fix broken doc references due to renames
  docs: pdf: add all Documentation/*/index.rst to PDF output
  docs: conf.py: add CJK package needed by translations
  docs: conf.py: only use CJK if the font is available
  scripts/sphinx-pre-install: fix script for RHEL/CentOS
  scripts/sphinx-pre-install: don't use LaTeX with CentOS 7
  scripts/sphinx-pre-install: fix latexmk dependencies
  scripts/sphinx-pre-install: cleanup Gentoo checks
  scripts/sphinx-pre-install: seek for Noto CJK fonts for pdf output
  docs: load_config.py: avoid needing a conf.py just due to LaTeX docs
  docs: remove extra conf.py files
  docs: virtual: add it to the documentation body

 Documentation/PCI/pci-error-recovery.rst      |   5 +-
 Documentation/RCU/rculist_nulls.txt           |   2 +-
 Documentation/admin-guide/conf.py             |  10 --
 Documentation/conf.py                         |  30 +++-
 Documentation/core-api/conf.py                |  10 --
 Documentation/crypto/conf.py                  |  10 --
 Documentation/dev-tools/conf.py               |  10 --
 .../devicetree/bindings/arm/idle-states.txt   |   2 +-
 Documentation/doc-guide/conf.py               |  10 --
 Documentation/driver-api/80211/conf.py        |  10 --
 Documentation/driver-api/conf.py              |  10 --
 Documentation/driver-api/pm/conf.py           |  10 --
 Documentation/filesystems/conf.py             |  10 --
 Documentation/gpu/conf.py                     |  10 --
 Documentation/index.rst                       |   3 +
 Documentation/input/conf.py                   |  10 --
 Documentation/kernel-hacking/conf.py          |  10 --
 Documentation/locking/spinlocks.rst           |   4 +-
 Documentation/maintainer/conf.py              |  10 --
 Documentation/media/conf.py                   |  12 --
 Documentation/memory-barriers.txt             |   2 +-
 Documentation/networking/conf.py              |  10 --
 Documentation/power/index.rst                 |   2 +-
 .../{bootwrapper.txt => bootwrapper.rst}      |  28 +++-
 .../{cpu_families.txt => cpu_families.rst}    |  23 +--
 .../{cpu_features.txt => cpu_features.rst}    |   6 +-
 Documentation/powerpc/{cxl.txt => cxl.rst}    |  46 ++++--
 .../powerpc/{cxlflash.txt => cxlflash.rst}    |  10 +-
 .../{DAWR-POWER9.txt => dawr-power9.rst}      |  15 +-
 Documentation/powerpc/{dscr.txt => dscr.rst}  |  18 +-
 ...ecovery.txt => eeh-pci-error-recovery.rst} | 108 ++++++------
 ...ed-dump.txt => firmware-assisted-dump.rst} | 117 +++++++------
 Documentation/powerpc/{hvcs.txt => hvcs.rst}  | 108 ++++++------
 Documentation/powerpc/index.rst               |  34 ++++
 Documentation/powerpc/isa-versions.rst        |  15 +-
 .../powerpc/{mpc52xx.txt => mpc52xx.rst}      |  12 +-
 ...nv.txt => pci_iov_resource_on_powernv.rst} |  15 +-
 .../powerpc/{pmu-ebb.txt => pmu-ebb.rst}      |   1 +
 Documentation/powerpc/ptrace.rst              | 156 ++++++++++++++++++
 Documentation/powerpc/ptrace.txt              | 151 -----------------
 .../{qe_firmware.txt => qe_firmware.rst}      |  37 +++--
 .../{syscall64-abi.txt => syscall64-abi.rst}  |  29 ++--
 ...al_memory.txt => transactional_memory.rst} |  45 ++---
 Documentation/process/conf.py                 |  10 --
 Documentation/sh/conf.py                      |  10 --
 Documentation/sound/conf.py                   |  10 --
 Documentation/sphinx/load_config.py           |  27 ++-
 .../translations/ko_KR/memory-barriers.txt    |   2 +-
 Documentation/userspace-api/conf.py           |  10 --
 Documentation/virtual/kvm/index.rst           |   1 +
 Documentation/vm/conf.py                      |  10 --
 Documentation/watchdog/hpwdt.rst              |   2 +-
 Documentation/x86/conf.py                     |  10 --
 MAINTAINERS                                   |  14 +-
 arch/powerpc/kernel/exceptions-64s.S          |   2 +-
 drivers/gpu/drm/drm_modes.c                   |   2 +-
 drivers/i2c/busses/i2c-nvidia-gpu.c           |   2 +-
 drivers/scsi/hpsa.c                           |   4 +-
 drivers/soc/fsl/qe/qe.c                       |   2 +-
 drivers/tty/hvc/hvcs.c                        |   2 +-
 include/soc/fsl/qe/qe.h                       |   2 +-
 scripts/sphinx-pre-install                    | 118 ++++++++++---
 62 files changed, 738 insertions(+), 678 deletions(-)
 delete mode 100644 Documentation/admin-guide/conf.py
 delete mode 100644 Documentation/core-api/conf.py
 delete mode 100644 Documentation/crypto/conf.py
 delete mode 100644 Documentation/dev-tools/conf.py
 delete mode 100644 Documentation/doc-guide/conf.py
 delete mode 100644 Documentation/driver-api/80211/conf.py
 delete mode 100644 Documentation/driver-api/conf.py
 delete mode 100644 Documentation/driver-api/pm/conf.py
 delete mode 100644 Documentation/filesystems/conf.py
 delete mode 100644 Documentation/gpu/conf.py
 delete mode 100644 Documentation/input/conf.py
 delete mode 100644 Documentation/kernel-hacking/conf.py
 delete mode 100644 Documentation/maintainer/conf.py
 delete mode 100644 Documentation/media/conf.py
 delete mode 100644 Documentation/networking/conf.py
 rename Documentation/powerpc/{bootwrapper.txt => bootwrapper.rst} (93%)
 rename Documentation/powerpc/{cpu_families.txt => cpu_families.rst} (95%)
 rename Documentation/powerpc/{cpu_features.txt => cpu_features.rst} (97%)
 rename Documentation/powerpc/{cxl.txt => cxl.rst} (95%)
 rename Documentation/powerpc/{cxlflash.txt => cxlflash.rst} (98%)
 rename Documentation/powerpc/{DAWR-POWER9.txt => dawr-power9.rst} (95%)
 rename Documentation/powerpc/{dscr.txt => dscr.rst} (91%)
 rename Documentation/powerpc/{eeh-pci-error-recovery.txt => eeh-pci-error-recovery.rst} (82%)
 rename Documentation/powerpc/{firmware-assisted-dump.txt => firmware-assisted-dump.rst} (80%)
 rename Documentation/powerpc/{hvcs.txt => hvcs.rst} (91%)
 create mode 100644 Documentation/powerpc/index.rst
 rename Documentation/powerpc/{mpc52xx.txt => mpc52xx.rst} (91%)
 rename Documentation/powerpc/{pci_iov_resource_on_powernv.txt => pci_iov_resource_on_powernv.rst} (97%)
 rename Documentation/powerpc/{pmu-ebb.txt => pmu-ebb.rst} (99%)
 create mode 100644 Documentation/powerpc/ptrace.rst
 delete mode 100644 Documentation/powerpc/ptrace.txt
 rename Documentation/powerpc/{qe_firmware.txt => qe_firmware.rst} (95%)
 rename Documentation/powerpc/{syscall64-abi.txt => syscall64-abi.rst} (82%)
 rename Documentation/powerpc/{transactional_memory.txt => transactional_memory.rst} (93%)
 delete mode 100644 Documentation/process/conf.py
 delete mode 100644 Documentation/sh/conf.py
 delete mode 100644 Documentation/sound/conf.py
 delete mode 100644 Documentation/userspace-api/conf.py
 delete mode 100644 Documentation/vm/conf.py
 delete mode 100644 Documentation/x86/conf.py

-- 
2.21.0

^ permalink raw reply

* [PATCH 13/14] docs: remove extra conf.py files
From: Mauro Carvalho Chehab @ 2019-07-16 12:10 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Jonathan Corbet, Herbert Xu,
	David S. Miller, Maarten Lankhorst, Maxime Ripard, Sean Paul,
	David Airlie, Daniel Vetter, Dmitry Torokhov, Yoshinori Sato,
	Rich Felker, Jaroslav Kysela, Takashi Iwai, Thomas Gleixner,
	Ingo Molnar, Borislav Petkov, H. Peter Anvin, x86, linux-doc,
	linux-crypto, dri
In-Reply-To: <cover.1563277838.git.mchehab+samsung@kernel.org>

Now that the latex_documents are handled automatically, we can
remove those extra conf.py files.

Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
---
 Documentation/admin-guide/conf.py      | 10 ----------
 Documentation/core-api/conf.py         | 10 ----------
 Documentation/crypto/conf.py           | 10 ----------
 Documentation/dev-tools/conf.py        | 10 ----------
 Documentation/doc-guide/conf.py        | 10 ----------
 Documentation/driver-api/80211/conf.py | 10 ----------
 Documentation/driver-api/conf.py       | 10 ----------
 Documentation/driver-api/pm/conf.py    | 10 ----------
 Documentation/filesystems/conf.py      | 10 ----------
 Documentation/gpu/conf.py              | 10 ----------
 Documentation/input/conf.py            | 10 ----------
 Documentation/kernel-hacking/conf.py   | 10 ----------
 Documentation/maintainer/conf.py       | 10 ----------
 Documentation/media/conf.py            | 12 ------------
 Documentation/networking/conf.py       | 10 ----------
 Documentation/process/conf.py          | 10 ----------
 Documentation/sh/conf.py               | 10 ----------
 Documentation/sound/conf.py            | 10 ----------
 Documentation/userspace-api/conf.py    | 10 ----------
 Documentation/vm/conf.py               | 10 ----------
 Documentation/x86/conf.py              | 10 ----------
 21 files changed, 212 deletions(-)
 delete mode 100644 Documentation/admin-guide/conf.py
 delete mode 100644 Documentation/core-api/conf.py
 delete mode 100644 Documentation/crypto/conf.py
 delete mode 100644 Documentation/dev-tools/conf.py
 delete mode 100644 Documentation/doc-guide/conf.py
 delete mode 100644 Documentation/driver-api/80211/conf.py
 delete mode 100644 Documentation/driver-api/conf.py
 delete mode 100644 Documentation/driver-api/pm/conf.py
 delete mode 100644 Documentation/filesystems/conf.py
 delete mode 100644 Documentation/gpu/conf.py
 delete mode 100644 Documentation/input/conf.py
 delete mode 100644 Documentation/kernel-hacking/conf.py
 delete mode 100644 Documentation/maintainer/conf.py
 delete mode 100644 Documentation/media/conf.py
 delete mode 100644 Documentation/networking/conf.py
 delete mode 100644 Documentation/process/conf.py
 delete mode 100644 Documentation/sh/conf.py
 delete mode 100644 Documentation/sound/conf.py
 delete mode 100644 Documentation/userspace-api/conf.py
 delete mode 100644 Documentation/vm/conf.py
 delete mode 100644 Documentation/x86/conf.py

diff --git a/Documentation/admin-guide/conf.py b/Documentation/admin-guide/conf.py
deleted file mode 100644
index 86f738953799..000000000000
--- a/Documentation/admin-guide/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = 'Linux Kernel User Documentation'
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'linux-user.tex', 'Linux Kernel User Documentation',
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/core-api/conf.py b/Documentation/core-api/conf.py
deleted file mode 100644
index db1f7659f3da..000000000000
--- a/Documentation/core-api/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Core-API Documentation"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'core-api.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/crypto/conf.py b/Documentation/crypto/conf.py
deleted file mode 100644
index 4335d251ddf3..000000000000
--- a/Documentation/crypto/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = 'Linux Kernel Crypto API'
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'crypto-api.tex', 'Linux Kernel Crypto API manual',
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/dev-tools/conf.py b/Documentation/dev-tools/conf.py
deleted file mode 100644
index 7faafa3f7888..000000000000
--- a/Documentation/dev-tools/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Development tools for the kernel"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'dev-tools.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/doc-guide/conf.py b/Documentation/doc-guide/conf.py
deleted file mode 100644
index fd3731182d5a..000000000000
--- a/Documentation/doc-guide/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = 'Linux Kernel Documentation Guide'
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'kernel-doc-guide.tex', 'Linux Kernel Documentation Guide',
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/driver-api/80211/conf.py b/Documentation/driver-api/80211/conf.py
deleted file mode 100644
index 4424b4b0b9c3..000000000000
--- a/Documentation/driver-api/80211/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Linux 802.11 Driver Developer's Guide"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', '80211.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/driver-api/conf.py b/Documentation/driver-api/conf.py
deleted file mode 100644
index 202726d20088..000000000000
--- a/Documentation/driver-api/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "The Linux driver implementer's API guide"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'driver-api.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/driver-api/pm/conf.py b/Documentation/driver-api/pm/conf.py
deleted file mode 100644
index a89fac11272f..000000000000
--- a/Documentation/driver-api/pm/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Device Power Management"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'pm.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/filesystems/conf.py b/Documentation/filesystems/conf.py
deleted file mode 100644
index ea44172af5c4..000000000000
--- a/Documentation/filesystems/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Linux Filesystems API"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'filesystems.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/gpu/conf.py b/Documentation/gpu/conf.py
deleted file mode 100644
index 1757b040fb32..000000000000
--- a/Documentation/gpu/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Linux GPU Driver Developer's Guide"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'gpu.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/input/conf.py b/Documentation/input/conf.py
deleted file mode 100644
index d2352fdc92ed..000000000000
--- a/Documentation/input/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "The Linux input driver subsystem"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'linux-input.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/kernel-hacking/conf.py b/Documentation/kernel-hacking/conf.py
deleted file mode 100644
index 3d8acf0f33ad..000000000000
--- a/Documentation/kernel-hacking/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Kernel Hacking Guides"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'kernel-hacking.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/maintainer/conf.py b/Documentation/maintainer/conf.py
deleted file mode 100644
index 81e9eb7a7884..000000000000
--- a/Documentation/maintainer/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = 'Linux Kernel Development Documentation'
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'maintainer.tex', 'Linux Kernel Development Documentation',
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/media/conf.py b/Documentation/media/conf.py
deleted file mode 100644
index 1f194fcd2cae..000000000000
--- a/Documentation/media/conf.py
+++ /dev/null
@@ -1,12 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-# SPDX-License-Identifier: GPL-2.0
-
-project = 'Linux Media Subsystem Documentation'
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'media.tex', 'Linux Media Subsystem Documentation',
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/networking/conf.py b/Documentation/networking/conf.py
deleted file mode 100644
index 40f69e67a883..000000000000
--- a/Documentation/networking/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Linux Networking Documentation"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'networking.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/process/conf.py b/Documentation/process/conf.py
deleted file mode 100644
index 1b01a80ad9ce..000000000000
--- a/Documentation/process/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = 'Linux Kernel Development Documentation'
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'process.tex', 'Linux Kernel Development Documentation',
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/sh/conf.py b/Documentation/sh/conf.py
deleted file mode 100644
index 1eb684a13ac8..000000000000
--- a/Documentation/sh/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "SuperH architecture implementation manual"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'sh.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/sound/conf.py b/Documentation/sound/conf.py
deleted file mode 100644
index 3f1fc5e74e7b..000000000000
--- a/Documentation/sound/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Linux Sound Subsystem Documentation"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'sound.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/userspace-api/conf.py b/Documentation/userspace-api/conf.py
deleted file mode 100644
index 2eaf59f844e5..000000000000
--- a/Documentation/userspace-api/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "The Linux kernel user-space API guide"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'userspace-api.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/vm/conf.py b/Documentation/vm/conf.py
deleted file mode 100644
index 3b0b601af558..000000000000
--- a/Documentation/vm/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "Linux Memory Management Documentation"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'memory-management.tex', project,
-     'The kernel development community', 'manual'),
-]
diff --git a/Documentation/x86/conf.py b/Documentation/x86/conf.py
deleted file mode 100644
index 33c5c3142e20..000000000000
--- a/Documentation/x86/conf.py
+++ /dev/null
@@ -1,10 +0,0 @@
-# -*- coding: utf-8; mode: python -*-
-
-project = "X86 architecture specific documentation"
-
-tags.add("subproject")
-
-latex_documents = [
-    ('index', 'x86.tex', project,
-     'The kernel development community', 'manual'),
-]
-- 
2.21.0

^ permalink raw reply related

* Re: [PATCH 02/12] Documentation/arm: repointer docs to Documentation/arch/arm
From: Krzysztof Kozlowski @ 2019-07-16 14:51 UTC (permalink / raw)
  To: Alex Shi
  Cc: linux-doc, Jonathan Corbet, linux-kernel, linux-stm32,
	linux-arm-kernel, linuxppc-dev, linux-riscv, linux-omap,
	linux-fbdev, linux-samsung-soc@vger.kernel.org, linux-ia64,
	linux-mips, linux-parisc, linux-scsi, linux-s390, kvm, linux-sh,
	Kukjin Kim, linux-crypto, linux-input, linux-serial
In-Reply-To: <20190712022018.27989-2-alex.shi@linux.alibaba.com>

On Fri, 12 Jul 2019 at 04:20, Alex Shi <alex.shi@linux.alibaba.com> wrote:
>
> Since we move 'arm/arm64' docs to Documentation/arch/{arm,arm64} dir,
> redirect the doc pointer to them.
>
> Signed-off-by: Alex Shi <alex.shi@linux.alibaba.com>
> Cc: Jonathan Corbet <corbet@lwn.net>
> Cc: Kukjin Kim <kgene@kernel.org>
> Cc: Krzysztof Kozlowski <krzk@kernel.org>
> Cc: linux-doc@vger.kernel.org
> Cc: linux-kernel@vger.kernel.org
> Cc: linux-arm-kernel@lists.infradead.org
> Cc: linux-samsung-soc@vger.kernel.org
> Cc: linux-crypto@vger.kernel.org
> Cc: linux-input@vger.kernel.org
> Cc: linux-serial@vger.kernel.org
> ---
>  Documentation/arch/arm/Samsung-S3C24XX/GPIO.txt    |  2 +-
>  .../arch/arm/Samsung-S3C24XX/Overview.txt          |  6 +++---
>  Documentation/arch/arm/Samsung/GPIO.txt            |  2 +-
>  Documentation/arch/arm/Samsung/Overview.txt        |  4 ++--
>  Documentation/devicetree/bindings/arm/xen.txt      |  2 +-
>  Documentation/devicetree/booting-without-of.txt    |  4 ++--
>  Documentation/translations/zh_CN/arm/Booting       |  4 ++--
>  .../translations/zh_CN/arm/kernel_user_helpers.txt |  4 ++--
>  MAINTAINERS                                        |  6 +++---

I assume it will go through doc tree, so for Samsung:
Acked-by: Krzysztof Kozlowski <krzk@kernel.org>

Best regards,
Krzysztof

^ permalink raw reply

* Re: [PATCH -next] keyboard: remove set but not used variables 'sts'
From: Dmitry Torokhov @ 2019-07-16 18:17 UTC (permalink / raw)
  To: Mao Wenan; +Cc: linux-input, linux-kernel, kernel-janitors
In-Reply-To: <20190716085423.19443-1-maowenan@huawei.com>

On Tue, Jul 16, 2019 at 04:54:23PM +0800, Mao Wenan wrote:
> Fixes gcc '-Wunused-but-set-variable' warning:
> 
> drivers/input/keyboard/applespi.c: In function applespi_set_bl_level:
> drivers/input/keyboard/applespi.c:902:6: warning: variable sts set but not used [-Wunused-but-set-variable]
> 
> Fixes: b426ac0452093d ("Input: add Apple SPI keyboard and trackpad driver")
> 
> Signed-off-by: Mao Wenan <maowenan@huawei.com>

Applied, thank you.

> ---
>  drivers/input/keyboard/applespi.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/input/keyboard/applespi.c b/drivers/input/keyboard/applespi.c
> index c1a6843..548737e 100644
> --- a/drivers/input/keyboard/applespi.c
> +++ b/drivers/input/keyboard/applespi.c
> @@ -899,7 +899,6 @@ static void applespi_set_bl_level(struct led_classdev *led_cdev,
>  	struct applespi_data *applespi =
>  		container_of(led_cdev, struct applespi_data, backlight_info);
>  	unsigned long flags;
> -	int sts;
>  
>  	spin_lock_irqsave(&applespi->cmd_msg_lock, flags);
>  
> @@ -916,7 +915,7 @@ static void applespi_set_bl_level(struct led_classdev *led_cdev,
>  			 KBD_BL_LEVEL_MIN);
>  	}
>  
> -	sts = applespi_send_cmd_msg(applespi);
> +	applespi_send_cmd_msg(applespi);
>  
>  	spin_unlock_irqrestore(&applespi->cmd_msg_lock, flags);
>  }
> -- 
> 2.7.4
> 

-- 
Dmitry

^ permalink raw reply

* Re: [PATCH v2 2/2] input: soc_button_array for newer surface devices
From: Maximilian Luz @ 2019-07-16 18:19 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: linux-kernel, linux-input, platform-driver-x86, Hans de Goede,
	Chen Yu, Darren Hart, Andy Shevchenko, Benjamin Tissoires
In-Reply-To: <20190716072135.GA806@penguin>


Hi,

On 7/16/19 9:21 AM, Dmitry Torokhov wrote:
> When you are saying that Pro 4 and later models use different
> notifications, does this mean that Pro 4 does not define any GPIOs?

Unfortunately, at least the Surface Book (first generation, buttons are
handled the same way as on the Pro 4) has GPIOs defined in MSHW0040, but
they are for different use. Specifically: They can detect if the
clipboard (screen part of the device, the device basically has two parts
that can be separated: clipboard and base) is being removed. Relying on
the GPIOs was my first idea too, but that has been reported to shut down
the Book 1 when the clipboard is detached.

As far as I know, the OEM platform revision check is the easiest way to
differentiate between those devices.

> I do not believe -EAGAIN has any special meaning in the driver core;

I think I got the -EAGAIN from an outdated LWN article when I first
started working on this, thanks for confirming.

> also when the GPIO controller is not ready gpiod_get() will return
> -EPROBE_DEFER, which is the prober way if signalling that some resource
> is not yet available and probe should be retries at a later time.
>
> Moreover, I do not believe that gpiod_count() needs GPIO controller to
> be ready, the count is taken from board firmware or static board file
> definition, so if gpiod_count() returns 0 it should be clear indication
> that the driver should not be used with the device.

Thank you for this insight, I will update the patch accordingly.

Maximilian

^ permalink raw reply

* Re: [PATCH] Input: psmouse - Fix build error of multiple definition
From: Dmitry Torokhov @ 2019-07-16 18:19 UTC (permalink / raw)
  To: YueHaibing; +Cc: allison, tglx, info, dilinger, linux-kernel, linux-input
In-Reply-To: <20190716065411.56780-1-yuehaibing@huawei.com>

On Tue, Jul 16, 2019 at 02:54:11PM +0800, YueHaibing wrote:
> trackpoint_detect() should be static inline while
> CONFIG_MOUSE_PS2_TRACKPOINT is not set. otherwire,we
> got building fails:
> 
> drivers/input/mouse/alps.o: In function `trackpoint_detect':
> alps.c:(.text+0x8e00): multiple definition of `trackpoint_detect'
> drivers/input/mouse/psmouse-base.o:psmouse-base.c:(.text+0x1b50): first defined here
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Fixes: 55e3d9224b60 ("Input: psmouse - allow disabing certain protocol extensions")
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>

Applied, thank you.

> ---
>  drivers/input/mouse/trackpoint.h | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/input/mouse/trackpoint.h b/drivers/input/mouse/trackpoint.h
> index 0afffe8..77110f3 100644
> --- a/drivers/input/mouse/trackpoint.h
> +++ b/drivers/input/mouse/trackpoint.h
> @@ -158,7 +158,8 @@ struct trackpoint_data {
>  #ifdef CONFIG_MOUSE_PS2_TRACKPOINT
>  int trackpoint_detect(struct psmouse *psmouse, bool set_properties);
>  #else
> -inline int trackpoint_detect(struct psmouse *psmouse, bool set_properties)
> +static inline int trackpoint_detect(struct psmouse *psmouse,
> +				    bool set_properties)
>  {
>  	return -ENOSYS;
>  }
> -- 
> 2.7.4
> 
> 

-- 
Dmitry

^ permalink raw reply

* Re: [PATCH v7 2/2] Input: add Apple SPI keyboard and trackpad driver.
From: Dmitry Torokhov @ 2019-07-16 18:47 UTC (permalink / raw)
  To: Ronald Tschalär
  Cc: Henrik Rydberg, Andy Shevchenko, Andrzej Hajda, Inki Dae,
	Greg Kroah-Hartman, Lukas Wunner, Federico Lorenzi,
	Laurent Pinchart, linux-input, dri-devel, linux-kernel
In-Reply-To: <20190419081926.13567-3-ronald@innovation.ch>

Hi Ronald,

On Fri, Apr 19, 2019 at 01:19:26AM -0700, Ronald Tschalär wrote:
> The keyboard and trackpad on recent MacBook's (since 8,1) and
> MacBookPro's (13,* and 14,*) are attached to an SPI controller instead
> of USB, as previously. The higher level protocol is not publicly
> documented and hence has been reverse engineered. As a consequence there
> are still a number of unknown fields and commands. However, the known
> parts have been working well and received extensive testing and use.
> 
> In order for this driver to work, the proper SPI drivers need to be
> loaded too; for MB8,1 these are spi_pxa2xx_platform and spi_pxa2xx_pci;
> for all others they are spi_pxa2xx_platform and intel_lpss_pci. For this
> reason enabling this driver in the config implies enabling the above
> drivers.

I applied the patch (but changed __u8 to u8 as that's preferred form for
inside the kernel, and added error handling for input_mt_init_slots) but
we need to do some more work on the driver.

My main issue is with registering touchpad device asynchronously,
independent from the probe() function. This means (as far as I can tell)
that any error is not really appropriately handled (as by that time it
is too late to signal errors from probe()) and devm functions are not
going to be called, leaving remnants of the resources in memory on
driver unload. It also brings in issues with suspend/resume (what
happens if you suspend really quickly while device is not registered
yet?), etc, etc.

Can we switch to calling DEV_INFO command synchronously from probe()? If
we are concerned about it taking relatively long time we can always
annotate the driver as having probe_type = PROBE_PREFER_ASYNCHRONOUS so
that other devices can be probed simultaneously with applespi.

Thanks.

-- 
Dmitry

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox