|
@@ -433,7 +433,7 @@ static ssize_t dgnc_tty_state_show(struct device *d, struct device_attribute *at
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -458,7 +458,7 @@ static ssize_t dgnc_tty_baud_show(struct device *d, struct device_attribute *att
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -483,7 +483,7 @@ static ssize_t dgnc_tty_msignals_show(struct device *d, struct device_attribute
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -517,7 +517,7 @@ static ssize_t dgnc_tty_iflag_show(struct device *d, struct device_attribute *at
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -542,7 +542,7 @@ static ssize_t dgnc_tty_cflag_show(struct device *d, struct device_attribute *at
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -567,7 +567,7 @@ static ssize_t dgnc_tty_oflag_show(struct device *d, struct device_attribute *at
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -592,7 +592,7 @@ static ssize_t dgnc_tty_lflag_show(struct device *d, struct device_attribute *at
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -617,7 +617,7 @@ static ssize_t dgnc_tty_digi_flag_show(struct device *d, struct device_attribute
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -642,7 +642,7 @@ static ssize_t dgnc_tty_rxcount_show(struct device *d, struct device_attribute *
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -667,7 +667,7 @@ static ssize_t dgnc_tty_txcount_show(struct device *d, struct device_attribute *
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|
|
@@ -692,7 +692,7 @@ static ssize_t dgnc_tty_name_show(struct device *d, struct device_attribute *att
|
|
|
|
|
|
if (!d)
|
|
if (!d)
|
|
return 0;
|
|
return 0;
|
|
- un = (struct un_t *) dev_get_drvdata(d);
|
|
|
|
|
|
+ un = dev_get_drvdata(d);
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
if (!un || un->magic != DGNC_UNIT_MAGIC)
|
|
return 0;
|
|
return 0;
|
|
ch = un->un_ch;
|
|
ch = un->un_ch;
|