forked from Minki/linux
nfc: s3fwrn5: constify s3fwrn5_phy_ops structures
The s3fwrn5_phy_ops structure is never modified, so declare it as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Acked-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
This commit is contained in:
parent
59df9bb25c
commit
c6b5df0daf
@ -147,7 +147,7 @@ static struct nci_ops s3fwrn5_nci_ops = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
int s3fwrn5_probe(struct nci_dev **ndev, void *phy_id, struct device *pdev,
|
int s3fwrn5_probe(struct nci_dev **ndev, void *phy_id, struct device *pdev,
|
||||||
struct s3fwrn5_phy_ops *phy_ops, unsigned int max_payload)
|
const struct s3fwrn5_phy_ops *phy_ops, unsigned int max_payload)
|
||||||
{
|
{
|
||||||
struct s3fwrn5_info *info;
|
struct s3fwrn5_info *info;
|
||||||
int ret;
|
int ret;
|
||||||
|
@ -125,7 +125,7 @@ static int s3fwrn5_i2c_write(void *phy_id, struct sk_buff *skb)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static struct s3fwrn5_phy_ops i2c_phy_ops = {
|
static const struct s3fwrn5_phy_ops i2c_phy_ops = {
|
||||||
.set_wake = s3fwrn5_i2c_set_wake,
|
.set_wake = s3fwrn5_i2c_set_wake,
|
||||||
.set_mode = s3fwrn5_i2c_set_mode,
|
.set_mode = s3fwrn5_i2c_set_mode,
|
||||||
.get_mode = s3fwrn5_i2c_get_mode,
|
.get_mode = s3fwrn5_i2c_get_mode,
|
||||||
|
@ -44,7 +44,7 @@ struct s3fwrn5_info {
|
|||||||
void *phy_id;
|
void *phy_id;
|
||||||
struct device *pdev;
|
struct device *pdev;
|
||||||
|
|
||||||
struct s3fwrn5_phy_ops *phy_ops;
|
const struct s3fwrn5_phy_ops *phy_ops;
|
||||||
unsigned int max_payload;
|
unsigned int max_payload;
|
||||||
|
|
||||||
struct s3fwrn5_fw_info fw_info;
|
struct s3fwrn5_fw_info fw_info;
|
||||||
@ -90,7 +90,7 @@ static inline int s3fwrn5_write(struct s3fwrn5_info *info, struct sk_buff *skb)
|
|||||||
}
|
}
|
||||||
|
|
||||||
int s3fwrn5_probe(struct nci_dev **ndev, void *phy_id, struct device *pdev,
|
int s3fwrn5_probe(struct nci_dev **ndev, void *phy_id, struct device *pdev,
|
||||||
struct s3fwrn5_phy_ops *phy_ops, unsigned int max_payload);
|
const struct s3fwrn5_phy_ops *phy_ops, unsigned int max_payload);
|
||||||
void s3fwrn5_remove(struct nci_dev *ndev);
|
void s3fwrn5_remove(struct nci_dev *ndev);
|
||||||
|
|
||||||
int s3fwrn5_recv_frame(struct nci_dev *ndev, struct sk_buff *skb,
|
int s3fwrn5_recv_frame(struct nci_dev *ndev, struct sk_buff *skb,
|
||||||
|
Loading…
Reference in New Issue
Block a user