Skip to content

Commit

Permalink
hamradio: baycom: make hdlcdrv_ops const
Browse files Browse the repository at this point in the history
Make hdlcdrv_ops structures const as they are only passed to
hdlcdrv_register function. The corresponding argument is of type const,
so make the structures const.

Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Bhumika Goyal authored and David S. Miller committed Aug 7, 2017
1 parent 13ead5c commit 511aeaf
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion drivers/net/hamradio/baycom_par.c
Original file line number Diff line number Diff line change
@@ -386,7 +386,7 @@ static int baycom_ioctl(struct net_device *dev, struct ifreq *ifr,

/* --------------------------------------------------------------------- */

static struct hdlcdrv_ops par96_ops = {
static const struct hdlcdrv_ops par96_ops = {
.drvname = bc_drvname,
.drvinfo = bc_drvinfo,
.open = par96_open,
2 changes: 1 addition & 1 deletion drivers/net/hamradio/baycom_ser_fdx.c
Original file line number Diff line number Diff line change
@@ -508,7 +508,7 @@ static int baycom_ioctl(struct net_device *dev, struct ifreq *ifr,

/* --------------------------------------------------------------------- */

static struct hdlcdrv_ops ser12_ops = {
static const struct hdlcdrv_ops ser12_ops = {
.drvname = bc_drvname,
.drvinfo = bc_drvinfo,
.open = ser12_open,
2 changes: 1 addition & 1 deletion drivers/net/hamradio/baycom_ser_hdx.c
Original file line number Diff line number Diff line change
@@ -542,7 +542,7 @@ static int baycom_ioctl(struct net_device *dev, struct ifreq *ifr,

/* --------------------------------------------------------------------- */

static struct hdlcdrv_ops ser12_ops = {
static const struct hdlcdrv_ops ser12_ops = {
.drvname = bc_drvname,
.drvinfo = bc_drvinfo,
.open = ser12_open,

0 comments on commit 511aeaf

Please sign in to comment.