* [PATCH 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic error for BX-59A
[not found] <20230731072148.4781-1-xingtong_wu@163.com>
@ 2023-08-01 9:07 ` xingtong_wu
2023-08-04 13:43 ` Ilpo Järvinen
0 siblings, 1 reply; 7+ messages in thread
From: xingtong_wu @ 2023-08-01 9:07 UTC (permalink / raw)
To: hdegoede, markgross, xingtong.wu, platform-driver-x86,
linux-kernel
Cc: gerd.haeussler.ext, tobias.schaffner, kernel test robot
From: "xingtong.wu" <xingtong.wu@siemens.com>
There is a bug in if statement that lead to logical error
and have influence to other IPC, it get correct now.
Fixes: c56beff20375 ("platform/x86/siemens: simatic-ipc-batt: add support for module BX-59A")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202308010001.BGYCSQrl-lkp@intel.com/
Signed-off-by: xingtong.wu <xingtong.wu@siemens.com>
---
drivers/platform/x86/siemens/simatic-ipc-batt.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/platform/x86/siemens/simatic-ipc-batt.c b/drivers/platform/x86/siemens/simatic-ipc-batt.c
index d66b9969234b..e6c12c52843c 100644
--- a/drivers/platform/x86/siemens/simatic-ipc-batt.c
+++ b/drivers/platform/x86/siemens/simatic-ipc-batt.c
@@ -194,7 +194,8 @@ int simatic_ipc_batt_probe(struct platform_device *pdev, struct gpiod_lookup_tab
if (table->table[2].key) {
flags = GPIOD_OUT_HIGH;
- if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A || SIMATIC_IPC_DEVICE_BX_59A)
+ if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A ||
+ priv.devmode == SIMATIC_IPC_DEVICE_BX_59A)
flags = GPIOD_OUT_LOW;
priv.gpios[2] = devm_gpiod_get_index(dev, "CMOSBattery meter", 2, flags);
if (IS_ERR(priv.gpios[2])) {
--
2.25.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic error for BX-59A
2023-08-01 9:07 ` [PATCH 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic error for BX-59A xingtong_wu
@ 2023-08-04 13:43 ` Ilpo Järvinen
2043-07-31 17:34 ` [PATCH v2 " xingtong_wu
0 siblings, 1 reply; 7+ messages in thread
From: Ilpo Järvinen @ 2023-08-04 13:43 UTC (permalink / raw)
To: xingtong_wu
Cc: hdegoede, markgross, xingtong.wu, platform-driver-x86,
linux-kernel, gerd.haeussler.ext, tobias.schaffner,
kernel test robot
[-- Attachment #1: Type: text/plain, Size: 1562 bytes --]
On Tue, 1 Aug 2023, xingtong_wu@163.com wrote:
> From: "xingtong.wu" <xingtong.wu@siemens.com>
>
> There is a bug in if statement that lead to logical error
> and have influence to other IPC, it get correct now.
>
> Fixes: c56beff20375 ("platform/x86/siemens: simatic-ipc-batt: add support for module BX-59A")
> Reported-by: kernel test robot <lkp@intel.com>
> Closes: https://lore.kernel.org/oe-kbuild-all/202308010001.BGYCSQrl-lkp@intel.com/
> Signed-off-by: xingtong.wu <xingtong.wu@siemens.com>
> ---
> drivers/platform/x86/siemens/simatic-ipc-batt.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/platform/x86/siemens/simatic-ipc-batt.c b/drivers/platform/x86/siemens/simatic-ipc-batt.c
> index d66b9969234b..e6c12c52843c 100644
> --- a/drivers/platform/x86/siemens/simatic-ipc-batt.c
> +++ b/drivers/platform/x86/siemens/simatic-ipc-batt.c
> @@ -194,7 +194,8 @@ int simatic_ipc_batt_probe(struct platform_device *pdev, struct gpiod_lookup_tab
>
> if (table->table[2].key) {
> flags = GPIOD_OUT_HIGH;
> - if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A || SIMATIC_IPC_DEVICE_BX_59A)
> + if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A ||
> + priv.devmode == SIMATIC_IPC_DEVICE_BX_59A)
> flags = GPIOD_OUT_LOW;
> priv.gpios[2] = devm_gpiod_get_index(dev, "CMOSBattery meter", 2, flags);
> if (IS_ERR(priv.gpios[2])) {
>
The code change is fine but please try to improve the changelog (has
similar problems as the other one).
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
--
i.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic error for BX-59A
2043-07-31 17:34 ` [PATCH v2 " xingtong_wu
@ 2023-08-07 9:00 ` Ilpo Järvinen
2043-08-02 17:38 ` [PATCH v3 2/2] platform/x86/siemens: simatic-ipc-batt: fix logical " xingtong_wu
2023-08-16 15:45 ` [PATCH v2 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic " Ashok Raj
1 sibling, 1 reply; 7+ messages in thread
From: Ilpo Järvinen @ 2023-08-07 9:00 UTC (permalink / raw)
To: xingtong_wu
Cc: hdegoede, markgross, xingtong.wu, platform-driver-x86, LKML,
gerd.haeussler.ext, tobias.schaffner, lkp
[-- Attachment #1: Type: text/plain, Size: 1770 bytes --]
On Sat, 1 Aug 2043, xingtong_wu@163.com wrote:
> From: "xingtong.wu" <xingtong.wu@siemens.com>
>
> The variable "priv.devmode" is missing from if statement that leads
> to a logical error. Add the missing variable to the if condition.
>
> Fixes: c56beff20375 ("platform/x86/siemens: simatic-ipc-batt: add support for module BX-59A")
> Reported-by: kernel test robot <lkp@intel.com>
> Closes: https://lore.kernel.org/oe-kbuild-all/202308010001.BGYCSQrl-lkp@intel.com/
>
> Signed-off-by: xingtong.wu <xingtong.wu@siemens.com>
The tags block should not have extra newlines like there's now one in
between Closes and Signed-off-by.
For patches 1-2:
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
(In case you end up submitting a new version, you should collect the tags
other people have given you, except e.g., if you did major modifications
to the patch.)
--
i.
> ---
> drivers/platform/x86/siemens/simatic-ipc-batt.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/platform/x86/siemens/simatic-ipc-batt.c b/drivers/platform/x86/siemens/simatic-ipc-batt.c
> index d66b9969234b..e6c12c52843c 100644
> --- a/drivers/platform/x86/siemens/simatic-ipc-batt.c
> +++ b/drivers/platform/x86/siemens/simatic-ipc-batt.c
> @@ -194,7 +194,8 @@ int simatic_ipc_batt_probe(struct platform_device *pdev, struct gpiod_lookup_tab
>
> if (table->table[2].key) {
> flags = GPIOD_OUT_HIGH;
> - if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A || SIMATIC_IPC_DEVICE_BX_59A)
> + if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A ||
> + priv.devmode == SIMATIC_IPC_DEVICE_BX_59A)
> flags = GPIOD_OUT_LOW;
> priv.gpios[2] = devm_gpiod_get_index(dev, "CMOSBattery meter", 2, flags);
> if (IS_ERR(priv.gpios[2])) {
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic error for BX-59A
2043-07-31 17:34 ` [PATCH v2 " xingtong_wu
2023-08-07 9:00 ` Ilpo Järvinen
@ 2023-08-16 15:45 ` Ashok Raj
2023-08-17 1:21 ` xingtong.wu
1 sibling, 1 reply; 7+ messages in thread
From: Ashok Raj @ 2023-08-16 15:45 UTC (permalink / raw)
To: xingtong_wu
Cc: ilpo.jarvinen, hdegoede, markgross, xingtong.wu,
platform-driver-x86, linux-kernel, gerd.haeussler.ext,
tobias.schaffner, lkp, Ashok Raj
On Sat, Aug 01, 2043 at 01:34:17AM +0800, xingtong_wu@163.com wrote:
^^^^^^^^^^^^^^^^^^^^
Nice way to keep your mail on top of the sort :-).. You need to fixup your
system date.
> From: "xingtong.wu" <xingtong.wu@siemens.com>
>
> The variable "priv.devmode" is missing from if statement that leads
> to a logical error. Add the missing variable to the if condition.
>
> Fixes: c56beff20375 ("platform/x86/siemens: simatic-ipc-batt: add support for module BX-59A")
> Reported-by: kernel test robot <lkp@intel.com>
> Closes: https://lore.kernel.org/oe-kbuild-all/202308010001.BGYCSQrl-lkp@intel.com/
>
> Signed-off-by: xingtong.wu <xingtong.wu@siemens.com>
> ---
> drivers/platform/x86/siemens/simatic-ipc-batt.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/platform/x86/siemens/simatic-ipc-batt.c b/drivers/platform/x86/siemens/simatic-ipc-batt.c
> index d66b9969234b..e6c12c52843c 100644
> --- a/drivers/platform/x86/siemens/simatic-ipc-batt.c
> +++ b/drivers/platform/x86/siemens/simatic-ipc-batt.c
> @@ -194,7 +194,8 @@ int simatic_ipc_batt_probe(struct platform_device *pdev, struct gpiod_lookup_tab
>
> if (table->table[2].key) {
> flags = GPIOD_OUT_HIGH;
> - if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A || SIMATIC_IPC_DEVICE_BX_59A)
> + if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A ||
> + priv.devmode == SIMATIC_IPC_DEVICE_BX_59A)
> flags = GPIOD_OUT_LOW;
> priv.gpios[2] = devm_gpiod_get_index(dev, "CMOSBattery meter", 2, flags);
> if (IS_ERR(priv.gpios[2])) {
> --
> 2.25.1
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic error for BX-59A
2023-08-16 15:45 ` [PATCH v2 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic " Ashok Raj
@ 2023-08-17 1:21 ` xingtong.wu
0 siblings, 0 replies; 7+ messages in thread
From: xingtong.wu @ 2023-08-17 1:21 UTC (permalink / raw)
To: Ashok Raj
Cc: ilpo.jarvinen, hdegoede, markgross, xingtong.wu,
platform-driver-x86, linux-kernel, gerd.haeussler.ext,
tobias.schaffner, lkp, Ashok Raj
On 2023/8/16 23:45, Ashok Raj wrote:
> On Sat, Aug 01, 2043 at 01:34:17AM +0800, xingtong_wu@163.com wrote:
> ^^^^^^^^^^^^^^^^^^^^
>
> Nice way to keep your mail on top of the sort :-).. You need to fixup your
> system date.
I'm sorry that there are time problem on my local machine which lead to a
wrong time in email, but I just sent an email to remind hdegoede@redhat.com
individually, the time problem was solved by him on his branch:
https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/commit/?h=review-hans&id=b01c1e022f7f0c327ecc7544dc44d5f80a2d2bd9
https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/commit/?h=review-hans&id=7abf253afa5c72c0c7eb21f67da1d443f036737a
>
>> From: "xingtong.wu" <xingtong.wu@siemens.com>
>>
>> The variable "priv.devmode" is missing from if statement that leads
>> to a logical error. Add the missing variable to the if condition.
>>
>> Fixes: c56beff20375 ("platform/x86/siemens: simatic-ipc-batt: add support for module BX-59A")
>> Reported-by: kernel test robot <lkp@intel.com>
>> Closes: https://lore.kernel.org/oe-kbuild-all/202308010001.BGYCSQrl-lkp@intel.com/
>>
>> Signed-off-by: xingtong.wu <xingtong.wu@siemens.com>
>> ---
>> drivers/platform/x86/siemens/simatic-ipc-batt.c | 3 ++-
>> 1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/platform/x86/siemens/simatic-ipc-batt.c b/drivers/platform/x86/siemens/simatic-ipc-batt.c
>> index d66b9969234b..e6c12c52843c 100644
>> --- a/drivers/platform/x86/siemens/simatic-ipc-batt.c
>> +++ b/drivers/platform/x86/siemens/simatic-ipc-batt.c
>> @@ -194,7 +194,8 @@ int simatic_ipc_batt_probe(struct platform_device *pdev, struct gpiod_lookup_tab
>>
>> if (table->table[2].key) {
>> flags = GPIOD_OUT_HIGH;
>> - if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A || SIMATIC_IPC_DEVICE_BX_59A)
>> + if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A ||
>> + priv.devmode == SIMATIC_IPC_DEVICE_BX_59A)
>> flags = GPIOD_OUT_LOW;
>> priv.gpios[2] = devm_gpiod_get_index(dev, "CMOSBattery meter", 2, flags);
>> if (IS_ERR(priv.gpios[2])) {
>> --
>> 2.25.1
>>
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH v2 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic error for BX-59A
2023-08-04 13:43 ` Ilpo Järvinen
@ 2043-07-31 17:34 ` xingtong_wu
2023-08-07 9:00 ` Ilpo Järvinen
2023-08-16 15:45 ` [PATCH v2 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic " Ashok Raj
0 siblings, 2 replies; 7+ messages in thread
From: xingtong_wu @ 2043-07-31 17:34 UTC (permalink / raw)
To: ilpo.jarvinen
Cc: hdegoede, markgross, xingtong.wu, platform-driver-x86,
linux-kernel, gerd.haeussler.ext, tobias.schaffner, lkp
From: "xingtong.wu" <xingtong.wu@siemens.com>
The variable "priv.devmode" is missing from if statement that leads
to a logical error. Add the missing variable to the if condition.
Fixes: c56beff20375 ("platform/x86/siemens: simatic-ipc-batt: add support for module BX-59A")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202308010001.BGYCSQrl-lkp@intel.com/
Signed-off-by: xingtong.wu <xingtong.wu@siemens.com>
---
drivers/platform/x86/siemens/simatic-ipc-batt.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/platform/x86/siemens/simatic-ipc-batt.c b/drivers/platform/x86/siemens/simatic-ipc-batt.c
index d66b9969234b..e6c12c52843c 100644
--- a/drivers/platform/x86/siemens/simatic-ipc-batt.c
+++ b/drivers/platform/x86/siemens/simatic-ipc-batt.c
@@ -194,7 +194,8 @@ int simatic_ipc_batt_probe(struct platform_device *pdev, struct gpiod_lookup_tab
if (table->table[2].key) {
flags = GPIOD_OUT_HIGH;
- if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A || SIMATIC_IPC_DEVICE_BX_59A)
+ if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A ||
+ priv.devmode == SIMATIC_IPC_DEVICE_BX_59A)
flags = GPIOD_OUT_LOW;
priv.gpios[2] = devm_gpiod_get_index(dev, "CMOSBattery meter", 2, flags);
if (IS_ERR(priv.gpios[2])) {
--
2.25.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v3 2/2] platform/x86/siemens: simatic-ipc-batt: fix logical error for BX-59A
2023-08-07 9:00 ` Ilpo Järvinen
@ 2043-08-02 17:38 ` xingtong_wu
0 siblings, 0 replies; 7+ messages in thread
From: xingtong_wu @ 2043-08-02 17:38 UTC (permalink / raw)
To: ilpo.jarvinen
Cc: hdegoede, markgross, xingtong.wu, platform-driver-x86,
linux-kernel, gerd.haeussler.ext, tobias.schaffner, lkp
From: "xingtong.wu" <xingtong.wu@siemens.com>
The variable "priv.devmode" is missing from if statement that leads
to a logical error. Add the missing variable to the if condition.
Fixes: c56beff20375 ("platform/x86/siemens: simatic-ipc-batt: add support for module BX-59A")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202308010001.BGYCSQrl-lkp@intel.com/
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: xingtong.wu <xingtong.wu@siemens.com>
---
drivers/platform/x86/siemens/simatic-ipc-batt.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/platform/x86/siemens/simatic-ipc-batt.c b/drivers/platform/x86/siemens/simatic-ipc-batt.c
index d66b9969234b..e6c12c52843c 100644
--- a/drivers/platform/x86/siemens/simatic-ipc-batt.c
+++ b/drivers/platform/x86/siemens/simatic-ipc-batt.c
@@ -194,7 +194,8 @@ int simatic_ipc_batt_probe(struct platform_device *pdev, struct gpiod_lookup_tab
if (table->table[2].key) {
flags = GPIOD_OUT_HIGH;
- if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A || SIMATIC_IPC_DEVICE_BX_59A)
+ if (priv.devmode == SIMATIC_IPC_DEVICE_BX_21A ||
+ priv.devmode == SIMATIC_IPC_DEVICE_BX_59A)
flags = GPIOD_OUT_LOW;
priv.gpios[2] = devm_gpiod_get_index(dev, "CMOSBattery meter", 2, flags);
if (IS_ERR(priv.gpios[2])) {
--
2.25.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
end of thread, other threads:[~2023-08-17 1:36 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20230731072148.4781-1-xingtong_wu@163.com>
2023-08-01 9:07 ` [PATCH 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic error for BX-59A xingtong_wu
2023-08-04 13:43 ` Ilpo Järvinen
2043-07-31 17:34 ` [PATCH v2 " xingtong_wu
2023-08-07 9:00 ` Ilpo Järvinen
2043-08-02 17:38 ` [PATCH v3 2/2] platform/x86/siemens: simatic-ipc-batt: fix logical " xingtong_wu
2023-08-16 15:45 ` [PATCH v2 2/2] platform/x86/siemens: simatic-ipc-batt: fix logic " Ashok Raj
2023-08-17 1:21 ` xingtong.wu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox