Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1715294 > unrolled thread
| Started by | Bhumika Goyal <bhumirks@gmail.com> |
|---|---|
| First post | 2017-08-18 18:10 +0200 |
| Last post | 2017-08-19 22:30 +0200 |
| Articles | 3 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH 0/2] drivers: make i2c_algorithm const Bhumika Goyal <bhumirks@gmail.com> - 2017-08-18 18:10 +0200
[PATCH 2/2] [media] usb: make i2c_algorithm const Bhumika Goyal <bhumirks@gmail.com> - 2017-08-18 18:10 +0200
Re: [PATCH 2/2] [media] usb: make i2c_algorithm const isely@isely.net - 2017-08-19 22:30 +0200
| From | Bhumika Goyal <bhumirks@gmail.com> |
|---|---|
| Date | 2017-08-18 18:10 +0200 |
| Subject | [PATCH 0/2] drivers: make i2c_algorithm const |
| Message-ID | <ufS0q-63B-7@gated-at.bofh.it> |
Make these const. Bhumika Goyal (2): i2c: busses: make i2c_algorithm const [media] usb: make i2c_algorithm const drivers/i2c/busses/i2c-pnx.c | 2 +- drivers/i2c/busses/i2c-puv3.c | 2 +- drivers/media/usb/au0828/au0828-i2c.c | 2 +- drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) -- 1.9.1
[toc] | [next] | [standalone]
| From | Bhumika Goyal <bhumirks@gmail.com> |
|---|---|
| Date | 2017-08-18 18:10 +0200 |
| Subject | [PATCH 2/2] [media] usb: make i2c_algorithm const |
| Message-ID | <ufS0r-63B-31@gated-at.bofh.it> |
| In reply to | #1715294 |
Make these const as they are only used in a copy operation or
are stored in the algo field of i2c_adapter structure, which is const.
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
---
drivers/media/usb/au0828/au0828-i2c.c | 2 +-
drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/media/usb/au0828/au0828-i2c.c b/drivers/media/usb/au0828/au0828-i2c.c
index 42b352b..a028e36 100644
--- a/drivers/media/usb/au0828/au0828-i2c.c
+++ b/drivers/media/usb/au0828/au0828-i2c.c
@@ -329,7 +329,7 @@ static u32 au0828_functionality(struct i2c_adapter *adap)
return I2C_FUNC_SMBUS_EMUL | I2C_FUNC_I2C;
}
-static struct i2c_algorithm au0828_i2c_algo_template = {
+static const struct i2c_algorithm au0828_i2c_algo_template = {
.master_xfer = i2c_xfer,
.functionality = au0828_functionality,
};
diff --git a/drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c b/drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c
index 20a52b7..cfa8fbe 100644
--- a/drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c
+++ b/drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c
@@ -514,7 +514,7 @@ static u32 pvr2_i2c_functionality(struct i2c_adapter *adap)
return I2C_FUNC_SMBUS_EMUL | I2C_FUNC_I2C;
}
-static struct i2c_algorithm pvr2_i2c_algo_template = {
+static const struct i2c_algorithm pvr2_i2c_algo_template = {
.master_xfer = pvr2_i2c_xfer,
.functionality = pvr2_i2c_functionality,
};
--
1.9.1
[toc] | [prev] | [next] | [standalone]
| From | isely@isely.net |
|---|---|
| Date | 2017-08-19 22:30 +0200 |
| Subject | Re: [PATCH 2/2] [media] usb: make i2c_algorithm const |
| Message-ID | <ugixz-5RV-5@gated-at.bofh.it> |
| In reply to | #1715295 |
Acked-by: Mike Isely <isely@pobox.com>
On Fri, 18 Aug 2017, Bhumika Goyal wrote:
> Make these const as they are only used in a copy operation or
> are stored in the algo field of i2c_adapter structure, which is const.
>
> Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
> ---
> drivers/media/usb/au0828/au0828-i2c.c | 2 +-
> drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/media/usb/au0828/au0828-i2c.c b/drivers/media/usb/au0828/au0828-i2c.c
> index 42b352b..a028e36 100644
> --- a/drivers/media/usb/au0828/au0828-i2c.c
> +++ b/drivers/media/usb/au0828/au0828-i2c.c
> @@ -329,7 +329,7 @@ static u32 au0828_functionality(struct i2c_adapter *adap)
> return I2C_FUNC_SMBUS_EMUL | I2C_FUNC_I2C;
> }
>
> -static struct i2c_algorithm au0828_i2c_algo_template = {
> +static const struct i2c_algorithm au0828_i2c_algo_template = {
> .master_xfer = i2c_xfer,
> .functionality = au0828_functionality,
> };
> diff --git a/drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c b/drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c
> index 20a52b7..cfa8fbe 100644
> --- a/drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c
> +++ b/drivers/media/usb/pvrusb2/pvrusb2-i2c-core.c
> @@ -514,7 +514,7 @@ static u32 pvr2_i2c_functionality(struct i2c_adapter *adap)
> return I2C_FUNC_SMBUS_EMUL | I2C_FUNC_I2C;
> }
>
> -static struct i2c_algorithm pvr2_i2c_algo_template = {
> +static const struct i2c_algorithm pvr2_i2c_algo_template = {
> .master_xfer = pvr2_i2c_xfer,
> .functionality = pvr2_i2c_functionality,
> };
>
--
Mike Isely
isely @ isely (dot) net
PGP: 03 54 43 4D 75 E5 CC 92 71 16 01 E2 B5 F5 C1 E8
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web