Skip to content

Commit

Permalink
net/atm/atm_sysfs.c: checkpatch cleanups
Browse files Browse the repository at this point in the history
Add space after for
Indent switch/case statements
80 column wrapping

Signed-off-by: Joe Perches <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
JoePerches authored and davem330 committed Jan 27, 2010
1 parent 3356b4d commit f0a6cb1
Showing 1 changed file with 14 additions and 13 deletions.
27 changes: 14 additions & 13 deletions net/atm/atm_sysfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,14 @@ static ssize_t show_atmaddress(struct device *cdev,

spin_lock_irqsave(&adev->lock, flags);
list_for_each_entry(aaddr, &adev->local, entry) {
for(i = 0, j = 0; i < ATM_ESA_LEN; ++i, ++j) {
for (i = 0, j = 0; i < ATM_ESA_LEN; ++i, ++j) {
if (j == *fmt) {
pos += sprintf(pos, ".");
++fmt;
j = 0;
}
pos += sprintf(pos, "%02x", aaddr->addr.sas_addr.prv[i]);
pos += sprintf(pos, "%02x",
aaddr->addr.sas_addr.prv[i]);
}
pos += sprintf(pos, "\n");
}
Expand Down Expand Up @@ -78,17 +79,17 @@ static ssize_t show_link_rate(struct device *cdev,

/* show the link rate, not the data rate */
switch (adev->link_rate) {
case ATM_OC3_PCR:
link_rate = 155520000;
break;
case ATM_OC12_PCR:
link_rate = 622080000;
break;
case ATM_25_PCR:
link_rate = 25600000;
break;
default:
link_rate = adev->link_rate * 8 * 53;
case ATM_OC3_PCR:
link_rate = 155520000;
break;
case ATM_OC12_PCR:
link_rate = 622080000;
break;
case ATM_25_PCR:
link_rate = 25600000;
break;
default:
link_rate = adev->link_rate * 8 * 53;
}
pos += sprintf(pos, "%d\n", link_rate);

Expand Down

0 comments on commit f0a6cb1

Please sign in to comment.