diff mbox

[2/3] wireless: ath9k: use %pM to print MAC

Message ID e9d4e9e2edf4c51412c141140d51e9baf9ff13a3.1311162926.git.andriy.shevchenko@linux.intel.com (mailing list archive)
State Not Applicable, archived
Headers show

Commit Message

Andy Shevchenko July 20, 2011, 1:34 p.m. UTC
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: "Luis R. Rodriguez" <lrodriguez@atheros.com>
Cc: ath9k-devel@lists.ath9k.org
---
 drivers/net/wireless/ath/ath9k/htc_drv_debug.c |    7 ++-----
 1 files changed, 2 insertions(+), 5 deletions(-)

Comments

Mohammed Shafi July 20, 2011, 3 p.m. UTC | #1
On Wed, Jul 20, 2011 at 7:04 PM, Andy Shevchenko
<andriy.shevchenko@linux.intel.com> wrote:
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> Cc: "Luis R. Rodriguez" <lrodriguez@atheros.com>
> Cc: ath9k-devel@lists.ath9k.org
> ---
>  drivers/net/wireless/ath/ath9k/htc_drv_debug.c |    7 ++-----
>  1 files changed, 2 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_debug.c b/drivers/net/wireless/ath/ath9k/htc_drv_debug.c
> index aa48b3a..d3ff33c 100644
> --- a/drivers/net/wireless/ath/ath9k/htc_drv_debug.c
> +++ b/drivers/net/wireless/ath/ath9k/htc_drv_debug.c
> @@ -623,11 +623,8 @@ static ssize_t read_file_base_eeprom(struct file *file, char __user *user_buf,
>                                pBase9287->openLoopPwrCntl);
>        }
>
> -       len += snprintf(buf + len, size - len,
> -                       "%20s : %02X:%02X:%02X:%02X:%02X:%02X\n",
> -                       "MacAddress",
> -                       pBase->macAddr[0], pBase->macAddr[1], pBase->macAddr[2],
> -                       pBase->macAddr[3], pBase->macAddr[4], pBase->macAddr[5]);
> +       len += snprintf(buf + len, size - len, "%20s : %pM\n", "MacAddress",
> +                       pBase->macAddr);
>        if (len > size)
>                len = size;

thanks for the patch!

>
> --
> 1.7.5.4
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
diff mbox

Patch

diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_debug.c b/drivers/net/wireless/ath/ath9k/htc_drv_debug.c
index aa48b3a..d3ff33c 100644
--- a/drivers/net/wireless/ath/ath9k/htc_drv_debug.c
+++ b/drivers/net/wireless/ath/ath9k/htc_drv_debug.c
@@ -623,11 +623,8 @@  static ssize_t read_file_base_eeprom(struct file *file, char __user *user_buf,
 				pBase9287->openLoopPwrCntl);
 	}
 
-	len += snprintf(buf + len, size - len,
-			"%20s : %02X:%02X:%02X:%02X:%02X:%02X\n",
-			"MacAddress",
-			pBase->macAddr[0], pBase->macAddr[1], pBase->macAddr[2],
-			pBase->macAddr[3], pBase->macAddr[4], pBase->macAddr[5]);
+	len += snprintf(buf + len, size - len, "%20s : %pM\n", "MacAddress",
+			pBase->macAddr);
 	if (len > size)
 		len = size;