aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/whci
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2015-02-13 17:37:53 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2015-02-14 00:21:38 -0500
commit125918dbd836d19b5dccc2690388b29e575f91a4 (patch)
treec8f4912388e074a6c37ec64fb74205a584b61acc /drivers/usb/host/whci
parentc7badc90178b89c49e3852a002024d26cef5f070 (diff)
usb: use %*pb[l] to print bitmaps including cpumasks and nodemasks
printk and friends can now format bitmaps using '%*pb[l]'. cpumask and nodemask also provide cpumask_pr_args() and nodemask_pr_args() respectively which can be used to generate the two printf arguments necessary to format the specified cpu/nodemask. * drivers/uwb/drp.c::uwb_drp_handle_alien_drp() was formatting mas.bm into a buffer but never used it. Removed. Signed-off-by: Tejun Heo <tj@kernel.org> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/usb/host/whci')
-rw-r--r--drivers/usb/host/whci/debug.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/usb/host/whci/debug.c b/drivers/usb/host/whci/debug.c
index ba61dae9e4d2..774b89d28fae 100644
--- a/drivers/usb/host/whci/debug.c
+++ b/drivers/usb/host/whci/debug.c
@@ -86,17 +86,14 @@ static void qset_print(struct seq_file *s, struct whc_qset *qset)
86static int di_print(struct seq_file *s, void *p) 86static int di_print(struct seq_file *s, void *p)
87{ 87{
88 struct whc *whc = s->private; 88 struct whc *whc = s->private;
89 char buf[72];
90 int d; 89 int d;
91 90
92 for (d = 0; d < whc->n_devices; d++) { 91 for (d = 0; d < whc->n_devices; d++) {
93 struct di_buf_entry *di = &whc->di_buf[d]; 92 struct di_buf_entry *di = &whc->di_buf[d];
94 93
95 bitmap_scnprintf(buf, sizeof(buf),
96 (unsigned long *)di->availability_info, UWB_NUM_MAS);
97
98 seq_printf(s, "DI[%d]\n", d); 94 seq_printf(s, "DI[%d]\n", d);
99 seq_printf(s, " availability: %s\n", buf); 95 seq_printf(s, " availability: %*pb\n",
96 UWB_NUM_MAS, (unsigned long *)di->availability_info);
100 seq_printf(s, " %c%c key idx: %d dev addr: %d\n", 97 seq_printf(s, " %c%c key idx: %d dev addr: %d\n",
101 (di->addr_sec_info & WHC_DI_SECURE) ? 'S' : ' ', 98 (di->addr_sec_info & WHC_DI_SECURE) ? 'S' : ' ',
102 (di->addr_sec_info & WHC_DI_DISABLE) ? 'D' : ' ', 99 (di->addr_sec_info & WHC_DI_DISABLE) ? 'D' : ' ',