projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6964e81
)
platform/x86: apple-gmux: use resource_size() with res
author
Wang Qing
<wangqing@vivo.com>
Tue, 14 Dec 2021 12:18:36 +0000
(
04:18
-0800)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Wed, 5 Jan 2022 11:42:33 +0000
(12:42 +0100)
[ Upstream commit
eb66fb03a727cde0ab9b1a3858de55c26f3007da
]
This should be (res->end - res->start + 1) here actually,
use resource_size() derectly.
Signed-off-by: Wang Qing <wangqing@vivo.com>
Link:
https://lore.kernel.org/r/1639484316-75873-1-git-send-email-wangqing@vivo.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/platform/x86/apple-gmux.c
patch
|
blob
|
history
diff --git
a/drivers/platform/x86/apple-gmux.c
b/drivers/platform/x86/apple-gmux.c
index 9aae45a452002cf842d9c5fb100010a2f843a6df..57553f9b4d1dcdc2f5514dc5382573a8d1b081bb 100644
(file)
--- a/
drivers/platform/x86/apple-gmux.c
+++ b/
drivers/platform/x86/apple-gmux.c
@@
-625,7
+625,7
@@
static int gmux_probe(struct pnp_dev *pnp, const struct pnp_device_id *id)
}
gmux_data->iostart = res->start;
- gmux_data->iolen = res
->end - res->start
;
+ gmux_data->iolen = res
ource_size(res)
;
if (gmux_data->iolen < GMUX_MIN_IO_LEN) {
pr_err("gmux I/O region too small (%lu < %u)\n",