0, sizeof(properties));
> +
> + mutex_lock(>lock);
> +
> + properties[prop_idx++] = PROPERTY_ENTRY_U32("gpio-sim,nr-gpios",
> + config->num_lines);
> +
> + if (config->label[0] != '\0')
> + properties[prop_idx++] = PROPERTY_ENTRY_STRING("gpio-sim,label",
> +config->label);
> +
> + if (config->line_names)
> + properties[prop_idx++] = PROPERTY_ENTRY_STRING_ARRAY_LEN(
> + "gpio-line-names",
> + config->line_names,
> + config->num_line_names);
> +
> + pdevinfo.id = ida_alloc(_sim_ida, GFP_KERNEL);
> + if (pdevinfo.id < 0) {
> + mutex_unlock(>lock);
> + return pdevinfo.id;
> + }
> +
> + pdevinfo.name = "gpio-sim";
> + pdevinfo.properties = properties;
> +
> + pdev = platform_device_register_full();
> + if (IS_ERR(pdev)) {
> + ida_free(_sim_ida, pdevinfo.id);
> + mutex_unlock(>lock);
> + return PTR_ERR(pdev);
> + }
> +
> + config->pdev = pdev;
> + mutex_unlock(>lock);
> +
> + return 0;
> +}
> +
> +static int gpio_sim_config_uncommit_item(struct config_item *item)
> +{
> + struct gpio_sim_chip_config *config = to_gpio_sim_chip_config(item);
> + int id;
> +
> + mutex_lock(>lock);
> + id = config->pdev->id;
> + platform_device_unregister(config->pdev);
> + config->pdev = NULL;
> + ida_free(_sim_ida, id);
Isn't it atomic per se? I mean that IDA won't give the same ID until you free
it. I.o.w. why is it under the mutex?
> + mutex_unlock(>lock);
> +
> + return 0;
> +}
> +
> +static struct configfs_group_operations gpio_sim_config_group_ops = {
> + .make_item = gpio_sim_config_make_item,
> + .commit_item= gpio_sim_config_commit_item,
> + .uncommit_item = gpio_sim_config_uncommit_item,
> +};
> +
> +static const struct config_item_type gpio_sim_config_type = {
> + .ct_group_ops = _sim_config_group_ops,
> + .ct_owner = THIS_MODULE,
> +};
> +
> +static struct configfs_subsystem gpio_sim_config_subsys = {
> + .su_group = {
> + .cg_item = {
> + .ci_namebuf = "gpio-sim",
> + .ci_type= _sim_config_type,
> + },
> + },
> +};
> +
> +static int __init gpio_sim_init(void)
> +{
> + int ret;
> +
> + ret = platform_driver_register(_sim_driver);
> + if (ret) {
> + pr_err("Error %d while registering the platform driver\n", ret);
> + return ret;
> + }
> +
> + config_group_init(_sim_config_subsys.su_group);
> + mutex_init(_sim_config_subsys.su_mutex);
> + ret = configfs_register_subsystem(_sim_config_subsys);
> + if (ret) {
> + pr_err("Error %d while registering the configfs subsystem %s\n",
> +ret, gpio_sim_config_subsys.su_group.cg_item.ci_namebuf);
> + mutex_destroy(_sim_config_subsys.su_mutex);
> + platform_driver_unregister(_sim_driver);
> + return ret;
> + }
> +
> + return 0;
> +}
> +module_init(gpio_sim_init);
> +
> +static void __exit gpio_sim_exit(void)
> +{
> + configfs_unregister_subsystem(_sim_config_subsys);
> + mutex_destroy(_sim_config_subsys.su_mutex);
> + platform_driver_unregister(_sim_driver);
> +}
> +module_exit(gpio_sim_exit);
> +
> +MODULE_AUTHOR("Bartosz Golaszewski ");
> +MODULE_DESCRIPTION("GPIO Simulator Module");
> +MODULE_LICENSE("GPL");
> --
> 2.29.1
>
--
With Best Regards,
Andy Shevchenko
On Thu, Mar 04, 2021 at 11:24:47AM +0100, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski
>
> Provide managed variants of bitmap_alloc() and bitmap_zalloc().
Reviewed-by: Andy Shevchenko
A few nit-picks below.
> Signed-off-by: Bartosz Golaszewski
> ---
> include/l
On Thu, Mar 04, 2021 at 11:24:46AM +0100, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski
>
> For better readability and maintenance: order the includes in bitmap
> source files alphabetically.
Reviewed-by: Andy Shevchenko
> Signed-off-by: Bartosz Golaszewski
> --
On Thu, Mar 04, 2021 at 11:24:45AM +0100, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski
>
> The 'extern' keyword doesn't have any benefits in header files. Remove it.
Reviewed-by: Andy Shevchenko
A few nitpicks below.
> Signed-off-by: Bartosz Golaszewski
> ---
&
On Thu, Mar 04, 2021 at 02:28:55PM +0200, Andy Shevchenko wrote:
> On Thu, Mar 04, 2021 at 11:10:48AM +0800, Li Wang wrote:
> > drivers/tty/vt/keyboard.c: In function 'vt_do_kdgkb_ioctl':
> > drivers/tty/vt/keyboard.c: warning: 'ret' may be used uninitialized in this
> &
ge,
and not just some output of some tool w/o context
- I want you to send a new version w/o chaining to the previous thread, so
start new (email) thread every time you send a new version
Waiting for v3 in a separate email thread, thanks!
--
With Best Regards,
Andy Shevchenko
On Thu, Mar 04, 2021 at 09:06:08AM +0100, Linus Walleij wrote:
> On Wed, Mar 3, 2021 at 10:35 AM Andy Shevchenko
> wrote:
> > On Wed, Mar 03, 2021 at 10:22:02AM +0100, Linus Walleij wrote:
>
> > > But this:
> > >
> > > > @@ -1504,15 +1497
On Thu, Mar 4, 2021 at 1:13 PM Álvaro Fernández Rojas wrote:
> > El 4 mar 2021, a las 11:49, Andy Shevchenko
> > escribió:
> > On Thu, Mar 4, 2021 at 10:57 AM Álvaro Fernández Rojas
> > wrote:
...
> >> + stat
On Thu, Mar 4, 2021 at 1:17 PM Álvaro Fernández Rojas wrote:
> > El 4 mar 2021, a las 11:43, Andy Shevchenko
> > escribió:
> > On Thu, Mar 4, 2021 at 10:57 AM Álvaro Fernández Rojas
> > wrote:
> >>
> >> Add a helper for registering BCM63XX pin co
On Thu, Mar 04, 2021 at 09:53:28AM +0100, Geert Uytterhoeven wrote:
> On Mon, Mar 1, 2021 at 6:00 PM Andy Shevchenko
> wrote:
> > At least one module will benefit from using next_arg() helper.
> > Let's export it for that module and others if they consider it
> > hel
On Thu, Mar 04, 2021 at 10:01:46AM +0100, Geert Uytterhoeven wrote:
> Hi Andy,
>
> On Mon, Mar 1, 2021 at 5:59 PM Andy Shevchenko
> wrote:
> > cmdline library provides next_arg() helper to traverse over parameters
> > and their values given in command line.
In IRQ handler interrupts are already disabled, hence no need
to repeat it. Even in the threaded case, which is disabled here,
it is not a problem because IRQ framework serializes descriptor
handling. Remove disabling IRQ part in the handler.
Signed-off-by: Andy Shevchenko
---
drivers/pinctrl
in % 16) * 2),
3UL => #define BLABLA GENMASK(1, 0)
> + mux << ((pin % 16) * 2));
...
> +static const struct of_device_id bcm6328_pinctrl_match[] = {
> + { .compatible = "brcm,bcm6328-pinctrl", },
> + { },
No comma.
> +};
Above comments to all your patches.
--
With Best Regards,
Andy Shevchenko
t; +struct bcm63xx_pinctrl {
> + struct device *dev;
> + struct regmap *regs;
> +
> + struct pinctrl_desc pctl_desc;
> + struct pinctrl_dev *pctl_dev;
> +
> + void *driver_data;
> +};
--
With Best Regards,
Andy Shevchenko
we use fwnode from day 1, please?
--
With Best Regards,
Andy Shevchenko
n);
> +#else
> +static inline int gpiochip_irqchip_add_domain(struct gpio_chip *gc,
> + struct irq_domain *domain)
> +{
> + WARN_ON(1);
> + return -EINVAL;
> +}
> +#endif
>
> int gpiochip_generic_request(struct gpio_chip *gc, unsigned int offset);
> v
On Thu, Mar 4, 2021 at 12:19 PM Andy Shevchenko
wrote:
> On Thu, Mar 4, 2021 at 9:29 AM Henning Schild
> wrote:
> I have given a few comments here and there, so please check the entire
> series and address them in _all_ similar locations. As I have noticed,
> I have different
s here and there, so please check the entire
series and address them in _all_ similar locations. As I have noticed,
I have different approach about P2SB code, I have to give the series a
dust and see if you can utilize it.
I would like to be Cc'ed on the next version.
--
With Best Regards,
Andy Shevchenko
ld) patch series I can send you privately for testing.
...
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License version 2 as
> + * published by the Free Software Foundation.
Not needed when you have SPDX.
...
> +#include
Wrong header. Should be types.h
...
> +#include
> +#include
Missed headers. You need to include ones that the code below is a
direct user of.
Like types.h
--
With Best Regards,
Andy Shevchenko
ical = pmc_clk_is_critical(d);
> + if (clk_data->critical)
> + pr_info("%s critclks quirk enabled\n", d->ident);
> }
...somewhere here?
Like
clk_data->critical = global_var;
if (...)
pr_info();
It seems it will reduce burden on a callback by dropping strcmp() call.
--
With Best Regards,
Andy Shevchenko
On Thu, Mar 4, 2021 at 2:31 AM Andrew Morton wrote:
> On Wed, 24 Feb 2021 10:39:36 +0200 Andy Shevchenko
> wrote:
...
> Also, why make them signed types? Negative Hz is physically
> nonsensical. If that upsets some code somewhere because it was dealing
> with signed t
> On Mar 3, 2021, at 10:11 AM, Daniel Xu wrote:
>
> On Tue, Mar 02, 2021 at 06:18:23PM -0800, Alexei Starovoitov wrote:
>>> On Tue, Mar 2, 2021 at 5:46 PM Andy Lutomirski wrote:
>>>
>>>
>>>> On Mar 2, 2021, at 5:22 PM, Alexei Starovoitov
&
ec689a8a8155ce8b966bd5d7737a3916f5e48be3.
Signed-off-by: Andy Shevchenko
---
drivers/mfd/lpc_sch.c | 32 ++--
1 file changed, 6 insertions(+), 26 deletions(-)
diff --git a/drivers/mfd/lpc_sch.c b/drivers/mfd/lpc_sch.c
index f27eb8dabc1c..428a526cbe86 100644
--- a/drivers/mfd/lpc_sch.c
d) functions, etc.
At least that was my (shallow) experience with perf last time I have tried it.
--
With Best Regards,
Andy Shevchenko
Hi,
> I'm also CC'ing Andy on this, who wrote the original assembly, in case
> he has some last minute objection.
Just "what took you so long":-) On potentially related note cryptogams
chacha-mips is as universal as poly1305-mips. "Universal" in sense that
it can be com
deed it is impossible to hit.
> >
> > but for compiler view, gcc should give 'used uninitialized' warning, too.
>
> Odd that no other compiler version does this right now, perhaps upgrade
> to a newer version of gcc? 8.2 is really old :(
But it's still supported. I think I can see why. We have a switch case without
default, and probably that's how it makes that happen. So, the proper fix is to
add default section AFAICT.
--
With Best Regards,
Andy Shevchenko
Switch to use module_parport_driver() to reduce boilerplate code.
Note, device_initcall() is a default for module_init().
Signed-off-by: Andy Shevchenko
Acked-by: Mark Brown
---
drivers/spi/spi-butterfly.c | 13 +
1 file changed, 1 insertion(+), 12 deletions(-)
diff --git
ose it could be surrounded by parenthesis or brackets and that
> would be a little better? I'll try this approach again and see what
> folks think.
But you can do:
Modules linked: module1 [buildidX]
module2 [buildidY]
module3 [buildidZ]
...
i.o.w. one module per line.
* Yes, I understand that downside maybe split message, so it's just for
consideration.
--
With Best Regards,
Andy Shevchenko
Introduce module_parport_driver() and use it.
Greg or Mark, since we have this series tagged, can somebody of you pick it up?
Changelog v3:
- added tag on patch 1 (Sudip)
- Cc'ed to Greg
Andy Shevchenko (3):
parport: Introduce module_parport_driver() helper macro
spi: butterfly: Switch
Kernel documentation validator is not happy:
.../keyboard.c:2195: warning: expecting prototype for vt_get_shiftstate().
Prototype was for vt_get_shift_state() instead
This is due to typo, fix it here.
Signed-off-by: Andy Shevchenko
---
drivers/tty/vt/keyboard.c | 2 +-
1 file changed, 1
On Wed, Mar 03, 2021 at 10:22:02AM +0100, Linus Walleij wrote:
> On Tue, Mar 2, 2021 at 4:35 PM Andy Shevchenko
> wrote:
>
> > When IRQ domain is created for an ACPI case, the name of it becomes
> > unknown-%d
> > since for now it utilizes of_node member only
Switch to use module_parport_driver() to reduce boilerplate code.
Signed-off-by: Andy Shevchenko
Acked-by: Mark Brown
---
drivers/spi/spi-lm70llp.c | 13 +
1 file changed, 1 insertion(+), 12 deletions(-)
diff --git a/drivers/spi/spi-lm70llp.c b/drivers/spi/spi-lm70llp.c
index
Introduce module_parport_driver() helper macro to reduce boilerplate
in the existing and new code.
Signed-off-by: Andy Shevchenko
Acked-by: Sudip Mukherjee
---
include/linux/parport.h | 12 +++-
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/include/linux/parport.h b
On Wed, Mar 3, 2021 at 10:44 AM Mauro Carvalho Chehab
wrote:
> Em Tue, 16 Feb 2021 19:12:58 +0200
> Andy Shevchenko escreveu:
> > On Tue, Feb 16, 2021 at 7:05 PM Jonathan Corbet wrote:
> > > Andy Shevchenko writes:
> > > > On Tue, Feb 16, 2021
On Wed, Mar 03, 2021 at 12:47:10AM +0100, Rikard Falkeborn wrote:
> Andy noted that constification of some static resource structs in
(If you wish, you may use Reported-by:, I'm fine with either way)
> intel_quark_i2c_gpio.c were incorrect. It turns out there is another
> change from
> On Mar 2, 2021, at 5:22 PM, Alexei Starovoitov
> wrote:
>
> On Tue, Mar 2, 2021 at 1:02 PM Andy Lutomirski wrote:
>>
>>
>>>> On Mar 2, 2021, at 12:24 PM, Alexei Starovoitov
>>>> wrote:
>>>
>>> On Tue, Mar 2, 2021 at 1
> On Mar 2, 2021, at 12:24 PM, Alexei Starovoitov
> wrote:
>
> On Tue, Mar 2, 2021 at 10:38 AM Andy Lutomirski wrote:
>>
>> Is there something like a uprobe test suite? How maintained /
>> actively used is uprobe?
>
> uprobe+bpf is heavily used in prod
> On Mar 2, 2021, at 12:25 PM, Oleg Nesterov wrote:
>
> On 03/01, Andy Lutomirski wrote:
>>
>>> On Mon, Mar 1, 2021 at 8:51 AM Oleg Nesterov wrote:
>>>
>>> But I guess this has nothing to do with uprobes, they do not single-step
>>> in ke
On Tue, Mar 02, 2021 at 05:07:55PM +0100, Bartosz Golaszewski wrote:
> On Tue, Mar 2, 2021 at 4:21 PM Andy Shevchenko
> wrote:
> Do you want me to take these, or will you include them in your PR?
I'll send PR.
I'm waiting for vger to process the queue (it has some lags).
--
With Bes
: warning: Function parameter or member 'fwnode' not described
in 'devm_irq_domain_create_sim'
.../irq_sim.c:240: warning: Excess function parameter 'fnode' description in
'devm_irq_domain_create_sim'
Signed-off-by: Andy Shevchenko
---
kernel/irq/irq_sim.c | 4 ++--
1 file changed, 2 insertions(+), 2
On Tue, Mar 02, 2021 at 05:34:48PM +0200, Andy Shevchenko wrote:
> We have (historically) different approaches how we identify the type
> of a given fwnode. Let's standardize them across the library code.
This patch has one functional mistake (see below), otherwise I will anyway wait
for
In the ACPI case we may use the firmware node in the similar way
as it's done for OF case. We may use that fwnode for other purposes
in the future.
Signed-off-by: Andy Shevchenko
---
drivers/gpio/gpiolib-acpi.c | 7 +++
drivers/gpio/gpiolib-acpi.h | 4
drivers/gpio/gpiolib.c | 1
per.
Amend gpiolib.c and gpiolib-of.c code in order to group OF operations.
Signed-off-by: Andy Shevchenko
---
drivers/gpio/gpiolib-of.c | 6 --
drivers/gpio/gpiolib.c| 9 -
2 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/drivers/gpio/gpiolib-of.c b/drivers/g
:
unknown-1 ==> \_SB.PCI0.GIP0.GPO
unknown-2 ==> \_SB.NIO3
Signed-off-by: Andy Shevchenko
---
drivers/gpio/gpiolib.c | 32
1 file changed, 12 insertions(+), 20 deletions(-)
diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c
We have (historically) different approaches how we identify the type
of a given fwnode. Let's standardize them across the library code.
Signed-off-by: Andy Shevchenko
---
drivers/gpio/gpiolib.c | 28 +---
1 file changed, 13 insertions(+), 15 deletions(-)
diff --git
; **\n");
> > + pr_warn("** the kernel, report this immediately to your system
> > **\n");
> > + pr_warn("** administrator!
> > **\n");
> > + pr_warn("**
> > **\n");
> > + pr_warn("** NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE
> > **\n");
> > +
> > pr_warn("**\n");
>
> Fortunately gcc is already smart enough to deduplicate identical strings,
> but only in the same source file.
--
With Best Regards,
Andy Shevchenko
future version of this, because some pieces of the code
(AFAICS from this message) looks suboptimal or dup or...
> On Tue, Feb 23, 2021 at 11:51 PM Asmaa Mnebhi wrote:
That said, will wait for v2 of this.
--
With Best Regards,
Andy Shevchenko
On Tue, Mar 02, 2021 at 05:14:30PM +0200, Mika Westerberg wrote:
> On Tue, Mar 02, 2021 at 05:09:24PM +0200, Andy Shevchenko wrote:
> > On Tue, Mar 02, 2021 at 03:48:43PM +0100, Linus Walleij wrote:
> > > On Thu, Feb 25, 2021 at 5:33 PM Andy Shevchenko
> > > wrote:
>
On Tue, Mar 02, 2021 at 02:51:45PM +, Sudip Mukherjee wrote:
> On Mon, Mar 1, 2021 at 12:12 PM Andy Shevchenko
> wrote:
> >
> > On Sun, Feb 28, 2021 at 11:27:10PM +, Sudip Mukherjee wrote:
> > > On Fri, Feb 26, 2021 at 07:03:09PM +0200, Andy Shevchenko wrote:
&
On Tue, Mar 02, 2021 at 03:48:43PM +0100, Linus Walleij wrote:
> On Thu, Feb 25, 2021 at 5:33 PM Andy Shevchenko
> wrote:
>
> > On some systems the ACPI tables has wrong pin number and instead of
> > having a relative one it provides an absolute one in the global
In ->remove() unregister resources in reversed order, i.e. MFD devices first
followed by I²C clock.
Signed-off-by: Andy Shevchenko
---
drivers/mfd/intel_quark_i2c_gpio.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/intel_quark_i2c_gpio.c
b/drivers/
I²C header provides a descriptive definitions for standard bus speeds.
Use them instead of plain numbers.
Signed-off-by: Andy Shevchenko
---
drivers/mfd/intel_quark_i2c_gpio.c | 9 +
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/mfd/intel_quark_i2c_gpio.c
b
It's convenient and less error prone to use definitions to address
different cells in an array. For this purpose we may reuse existing
BAR definitions.
Signed-off-by: Andy Shevchenko
---
drivers/mfd/intel_quark_i2c_gpio.c | 20 ++--
1 file changed, 10 insertions(+), 10 deletions
Cc: Rikard Falkeborn
Signed-off-by: Andy Shevchenko
---
drivers/mfd/intel_quark_i2c_gpio.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/mfd/intel_quark_i2c_gpio.c
b/drivers/mfd/intel_quark_i2c_gpio.c
index 55a9e017edee..124c0ee84169 100644
--- a/d
The device pointer in the custom structure is not used anywhere,
remove it for good.
Signed-off-by: Andy Shevchenko
---
drivers/mfd/intel_quark_i2c_gpio.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/mfd/intel_quark_i2c_gpio.c
b/drivers/mfd/intel_quark_i2c_gpio.c
index
The commit 8b9d6802583a ("ACPI: Constify acpi_bus helper functions,
switch to macros") only changed functions for CONFIG_ACPI=y case.
This part adjusts the rest.
Fixes: 8b9d6802583a ("ACPI: Constify acpi_bus helper functions, switch to
macros")
Cc: Sakari Ailus
Signed-off
in sata_dwc_isr(), which is odd.
Thanks for this information, it makes sense to me. Perhaps you need to
put this into the commit message to justify the need of the change.
> There is no issue currently does not
> mean it will never happen in the future. So I suggest the maintainer of
> function
> sata_dwc_isr() to fix this issue.
--
With Best Regards,
Andy Shevchenko
ot;checkpatch: look for symbolic permissions and suggest octal instead").
> >
> > Note: S_IFREG flag is added to the mode by __debugfs_create_file()
> > in fs/debugfs/inode.c
> >
> > Suggested-by: Andy Shevchenko
> > Signed-off-by: Drew Fustini
>
> Patch
be6eJSE8Lk0bmu+ehYVMoYOng+JYHDWhSK67k6
> 05ijTQz52Yi+kDqCu3ZVzI7dzdp3KcMuOnEf5w0kRAaUa/5ZetwcIn9cy+UGtN6S
> ZGsi4qu+ATziw0L3nPeWQ3TDIV9tI98qRo2Dger9uuXcdz8CgcA1J+UJh7WX9kT4
> OBIKkb1TftyT2LZyzBh2LcrueUIU3gka8IqI6X/B9lB6WTLCtuBGWZZLRAuuuWlL
> nEm2TuTtU0Ir7/3lnZ/Fmc5/Ams4cGfxl1oXdiXoARSLR6HdvIIBZ8GdUqISR1M1
> IMMQtRIWomsRCfN0IUvgi0bTUkE5dZp8UFThZp22CahWgEq5h63pNF0K8hHdEyWb
> aaMCoAFhIcU4UBUDUxREyY7y1eUCWKAl0B4xEvJoxolbYyTvQB4=
> -END RSA PRIVATE KEY-
>
> good luck!
>
> Tianjia
>
--
Andy Lutomirski
AMA Capital Management, LLC
On Mon, Mar 1, 2021 at 6:22 PM Masami Hiramatsu wrote:
>
> Hi Oleg and Andy,
>
> On Mon, 1 Mar 2021 17:51:31 +0100
> Oleg Nesterov wrote:
>
> > Hi Andy,
> >
> > sorry for delay.
> >
> > On 02/23, Andy Lutomirski wrote:
> > >
> > &
On Mon, Mar 1, 2021 at 8:51 AM Oleg Nesterov wrote:
>
> Hi Andy,
>
> sorry for delay.
>
> On 02/23, Andy Lutomirski wrote:
> >
> > A while back, I let myself be convinced that kprobes genuinely need to
> > single-step the kernel on occasion, and I decided t
> On Mar 1, 2021, at 11:02 AM, Luck, Tony wrote:
>
>
>>
>> Some programs may use read(2), write(2), etc as ways to check if
>> memory is valid without getting a signal. They might not want
>> signals, which means that this feature might need to be configurable.
>
> That sounds like an
At least one module will benefit from using next_arg() helper.
Let's export it for that module and others if they consider it
helpful.
Signed-off-by: Andy Shevchenko
---
lib/cmdline.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/cmdline.c b/lib/cmdline.c
index 5d474c626e24
cmdline library provides next_arg() helper to traverse over parameters
and their values given in command line. Replace custom approach in the driver
by it.
Signed-off-by: Andy Shevchenko
---
drivers/gpio/gpio-aggregator.c | 39 +-
1 file changed, 5 insertions
atches applied, thanks!
Ooops, you are fast!
Anyway, I have tested with gpio-aggregator (w/o this series it
sparkles with all possible bugs).
Tested-by: Andy Shevchenko
--
With Best Regards,
Andy Shevchenko
On Mon, Mar 01, 2021 at 04:34:41PM +0100, Jiri Kosina wrote:
> On Mon, 1 Mar 2021, Benjamin Tissoires wrote:
> > On Fri, Feb 26, 2021 at 8:34 PM Andy Shevchenko
> > wrote:
> > >
> > > The driver depends on ACPI, ACPI_PTR() resolution is always the same.
>
se a failure with
> nodes that are already registered.
>
> Fixing that by incrementing the reference count of the nodes
> that have already been registered, and only registering the
> new nodes. Also, clarifying the behaviour in the function
> documentation.
Reviewed-by: An
On Mon, Mar 01, 2021 at 05:30:11PM +0300, Heikki Krogerus wrote:
> Software node can not be registered before its parent.
Reviewed-by: Andy Shevchenko
Tested-by: Andy Shevchenko
(On Intel Galileo Gen 2 with some custom patches to convert gpio-dwapb et al.
to use swnodes. Those patc
There is no point to have non-constant device properties in this driver.
Thus, constify them for good.
Signed-off-by: Andy Shevchenko
---
drivers/mfd/intel-lpss-acpi.c | 8
drivers/mfd/intel-lpss-pci.c | 10 +-
drivers/mfd/intel-lpss.h | 2 +-
3 files changed, 10
From: Heikki Krogerus
The old device property API is going to be removed and
replaced with the newer software node API. This prepares MFD
subsystem for the transition.
Signed-off-by: Heikki Krogerus
Signed-off-by: Andy Shevchenko
---
drivers/mfd/mfd-core.c | 9 +
include/linux/mfd
From: Heikki Krogerus
Software node was always created for the device if it was
supplied with additional device properties, so those nodes
might as well be constant.
Signed-off-by: Heikki Krogerus
Signed-off-by: Andy Shevchenko
---
drivers/mfd/intel-lpss-acpi.c | 24
From: Heikki Krogerus
>From now on only accepting complete software nodes.
Signed-off-by: Heikki Krogerus
Signed-off-by: Andy Shevchenko
---
drivers/mfd/mfd-core.c | 6 --
include/linux/mfd/core.h | 4
2 files changed, 10 deletions(-)
diff --git a/drivers/mfd/mfd-core.c b/driv
On Mon, Mar 01, 2021 at 02:57:53PM +0100, Bartosz Golaszewski wrote:
> On Thu, Feb 25, 2021 at 4:07 PM Andy Shevchenko
> wrote:
> > On Tue, Feb 23, 2021 at 01:51:53PM +0200, Andy Shevchenko wrote:
> > > On Tue, Feb 23, 2021 at 04:35:58PM +0800, Yang Li wrote:
> &
tem() or so.
--
With Best Regards,
Andy Shevchenko
on 2016 and 2017 MacBookPro's, also known as the iBridge. The
> drivers
> + for the Touch Bar (apple-touchbar) and light sensor (hid-sensor-hub
> + and hid-sensor-als) need to be enabled separately.
> +
> + To compile this driver as a module, choose M here: the
> + module will be called apple-ibridge.
--
With Best Regards,
Andy Shevchenko
follow everything that some (non-ideal) tool
reports? I don't think so.
For all my experiments with that hardware, I haven't heard about the
issue with NULL pointers. Useless checks make code harder to read and
CPU to waste cycles. It might be maintainers of this driver consider
otherwise, so not my call.
--
With Best Regards,
Andy Shevchenko
sgs[outcnt++] = _buf;
> + }
...
> +
> +
One blank line is enough.
...
> + ret = virtio_i2c_send_reqs(vq, reqs, msgs, num);
> + if (ret == 0)
> + goto err_unlock_free;
> + else
Redundant.
> + nr = ret;
--
With Best Regards,
Andy Shevchenko
On Sun, Feb 28, 2021 at 11:27:10PM +, Sudip Mukherjee wrote:
> On Fri, Feb 26, 2021 at 07:03:09PM +0200, Andy Shevchenko wrote:
> > On Tue, Feb 16, 2021 at 01:07:39PM +0200, Andy Shevchenko wrote:
> > > Introduce module_parport_driver() helper macro to reduce boilerplate
>
d SMBus support bidirectional transfers as well. I think two buffers is
the right thing to do.
--
With Best Regards,
Andy Shevchenko
On Mon, Mar 01, 2021 at 02:09:25PM +0200, Andy Shevchenko wrote:
> On Mon, Mar 01, 2021 at 05:24:41PM +0530, Viresh Kumar wrote:
> > On 01-03-21, 14:41, Jie Deng wrote:
> > > +/**
> > > + * struct virtio_i2c_req - the virtio I2C request structure
> > > + * @o
enum iio_event_info info, int *val,
> > + int *val2)
Ditto.
...
> > +static int __maybe_unused tsl2591_resume(struct device *dev)
> > +{
> > + struct iio_dev *indio_dev = dev_get_drvdata(dev);
> > + struct tsl2591_chip *chip = iio_priv(indio_dev);
> > + int ret;
> > + int power_state;
> > +
> > + if (chip->events_enabled)
> > + power_state = TSL2591_PWR_ON |
> > + TSL2591_ENABLE_ALS_INT |
> > + TSL2591_ENABLE_ALS;
At least the last two can be on one line.
> > + else
> > + power_state = TSL2591_PWR_ON | TSL2591_ENABLE_ALS;
> > +
> > + mutex_lock(>als_mutex);
> > + ret = tsl2591_set_power_state(chip, power_state);
> > + mutex_unlock(>als_mutex);
> > +
> > + return ret;
> > +}
...
> > +static const struct dev_pm_ops tsl2591_pm_ops = {
> > + SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend,
> > + pm_runtime_force_resume)
One line?
> > + SET_RUNTIME_PM_OPS(tsl2591_suspend, tsl2591_resume, NULL)
> > +};
...
> > +static irqreturn_t tsl2591_event_handler(int irq, void *private)
> > +{
> > + /* Clear ALS irq */
> > + ret = i2c_smbus_write_byte(client, TSL2591_CMD_SF_CALS_NPI);
> > + if (ret < 0)
> > + dev_err(>dev, "Failed to clear als irq\n");
In the IRQ handler? Hmm... It potentially floods the logs.
> > + return IRQ_HANDLED;
> > +}
...
> > +static const struct of_device_id tsl2591_of_match[] = {
> > + { .compatible = "amstaos,tsl2591"},
> > + {},
Comma is not needed on the terminator line.
> > +};
--
With Best Regards,
Andy Shevchenko
reproduce this?
--
With Best Regards,
Andy Shevchenko
On Sun, Feb 28, 2021 at 11:29 AM Andy Shevchenko
wrote:
>
> On Sun, Feb 28, 2021 at 11:07 AM Andy Shevchenko
> wrote:
> > On Friday, February 26, 2021, Rasmus Villemoes
> > wrote:
> >>
> >> The only purpose of this driver is to serve as a consumer of t
On Sun, Feb 28, 2021 at 11:07 AM Andy Shevchenko
wrote:
> On Friday, February 26, 2021, Rasmus Villemoes
> wrote:
>>
>> The only purpose of this driver is to serve as a consumer of the input
>> clock, to prevent it from being disabled by clk_disable_unused().
>
On Wed, Feb 24, 2021 at 8:47 PM Aili Yao wrote:
>
> On Tue, 23 Feb 2021 08:42:59 -0800
> "Luck, Tony" wrote:
>
> > On Tue, Feb 23, 2021 at 07:33:46AM -0800, Andy Lutomirski wrote:
> > >
> > > > On Feb 23, 2021, at 4:44 AM, Aili Yao wrote:
&
Switch to the new style i2c-driver probe_new probe function.
Signed-off-by: Andy Shevchenko
---
v2: new patch
drivers/hid/i2c-hid/i2c-hid-acpi.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/hid/i2c-hid/i2c-hid-acpi.c
b/drivers/hid/i2c-hid/i2c-hid-acpi.c
Move static GUID variable out of the function and add a comment
how it looks like in the human readable representation.
While at it, include uuid.h since the guid_t type is defined in it.
Signed-off-by: Andy Shevchenko
---
v2: rebased on top of patch 1 that used to be separate change
drivers
Currently the ACPI companion and handle are retrieved and checked
a few times in different functions. Instead get ACPI companion only
once and reuse it everywhere.
Signed-off-by: Andy Shevchenko
---
v2: used companion indeed everywhere (i2c_hid_acpi_shutdown_tail() included)
drivers/hid/i2c-hid
The driver depends on ACPI, ACPI_PTR() resolution is always the same.
Otherwise a compiler may produce a warning.
That said, the rule of thumb either ugly ifdeffery with ACPI_PTR or
none should be used in a driver.
Signed-off-by: Andy Shevchenko
---
v2: no changes
drivers/hid/i2c-hid/i2c-hid
On Fri, Feb 26, 2021 at 8:35 PM Andy Shevchenko
wrote:
>
> The driver depends on ACPI, ACPI_PTR() resolution is always the same.
> Otherwise a compiler may produce a warning.
>
> That said, the rule of thumb either ugly ifdeffery with ACPI_PTR or
> none should be used in a drive
On Fri, Feb 26, 2021 at 8:32 PM Andy Shevchenko
wrote:
>
> Move static GUID variable out of the function and add a comment
> how it looks like in the human readable representation.
>
> While at it, include uuid.h since the guid_t type is defined in it.
Oh, I see more improvements
On Fri, Feb 26, 2021 at 8:44 PM Andy Shevchenko
wrote:
>
> Currently the ACPI companion and handle are retrieved and checked
> a few times in different functions. Instead get ACPI companion only
> once and reuse it everywhere.
>
> Signed-off-by: Andy Shevchenko
> ---
>
&g
Currently the ACPI companion and handle are retrieved and checked
a few times in different functions. Instead get ACPI companion only
once and reuse it everywhere.
Signed-off-by: Andy Shevchenko
---
It depends on previously sent patch that moves GUID out of the function.
If needed I can resend
The driver depends on ACPI, ACPI_PTR() resolution is always the same.
Otherwise a compiler may produce a warning.
That said, the rule of thumb either ugly ifdeffery with ACPI_PTR or
none should be used in a driver.
Signed-off-by: Andy Shevchenko
---
drivers/hid/i2c-hid/i2c-hid-acpi.c | 2 +-
1
Move static GUID variable out of the function and add a comment
how it looks like in the human readable representation.
While at it, include uuid.h since the guid_t type is defined in it.
Signed-off-by: Andy Shevchenko
---
drivers/hid/i2c-hid/i2c-hid-acpi.c | 9 ++---
1 file changed, 6
On Tue, Feb 16, 2021 at 01:31:48PM +0200, Andy Shevchenko wrote:
> When requesting optional GPIO echo line, bail out on error,
> so user will know that something wrong with the existing property.
Guys, any comments on this series?
> Signed-off-by: Andy Shevchenko
> ---
> driv
On Tue, Feb 16, 2021 at 01:07:39PM +0200, Andy Shevchenko wrote:
> Introduce module_parport_driver() helper macro to reduce boilerplate
> in the existing and new code.
Sudip, any comments on this?
> Signed-off-by: Andy Shevchenko
> ---
> v2: fixed typo in the macro
> inclu
place some code in pcim_release(),
> they are equivalent, and no functional change. It is more explicit
> that pcim_alloc_irq_vectors() is a device-managed function.
Thanks!
Reviewed-by: Andy Shevchenko
> Suggested-by: Andy Shevchenko
> Signed-off-by: Dejin Zheng
> ---
> v4
v4l2_pix_format structure
> directly. This reduces the stack usage to 612 bytes, and it could
> be reduced further by only storing the three members that are used.
Good to me!
Reviewed-by: Andy Shevchenko
> Signed-off-by: Arnd Bergmann
> ---
> .../staging/media/atomisp/pci/atom
OPROBE set
unexpected IRQ trap at vector 20
Fixes: ba8c90c61847 ("gpio: pca953x: Override IRQ for one of the expanders on
Galileo Gen 2")
Depends-on: 0ea683931adb ("gpio: dwapb: Convert driver to using the
GPIO-lib-based IRQ-chip")
Signed-off-by: Andy Shev
901 - 1000 of 41493 matches
Mail list logo