uwb: add debug prints during channel change and beacon actions
authorThomas Pugliese <thomas.pugliese@gmail.com>
Fri, 20 Dec 2013 17:54:07 +0000 (11:54 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 20 Dec 2013 20:19:13 +0000 (12:19 -0800)
Add debug prints during channel change and beacon actions.

Signed-off-by: Thomas Pugliese <thomas.pugliese@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/uwb/beacon.c
drivers/uwb/radio.c

index dcdd59bfcd09cff5e7cc0d9235af3850dad287e5..7b763610ce75ecaeebc963362306b468aefaaae8 100644 (file)
@@ -117,6 +117,7 @@ int uwb_rc_beacon(struct uwb_rc *rc, int channel, unsigned bpst_offset)
        int result;
        struct device *dev = &rc->uwb_dev.dev;
 
+       dev_dbg(dev, "%s: channel = %d\n", __func__, channel);
        if (channel < 0)
                channel = -1;
        if (channel == -1)
@@ -517,7 +518,7 @@ int uwbd_evt_handle_rc_bp_slot_change(struct uwb_event *evt)
 
        mutex_lock(&rc->uwb_dev.mutex);
        if (uwb_rc_evt_bp_slot_change_no_slot(bpsc)) {
-               dev_info(dev, "stopped beaconing: No free slots in BP\n");
+               dev_err(dev, "stopped beaconing: No free slots in BP\n");
                rc->beaconing = -1;
        } else
                rc->uwb_dev.beacon_slot = uwb_rc_evt_bp_slot_change_slot_num(bpsc);
index d58dfecf9a7981950477a5f9995109c0764f932a..10adb980099938bbb5d5dad33ec62c73327959d1 100644 (file)
@@ -62,6 +62,10 @@ static void uwb_radio_channel_changed(struct uwb_rc *rc, int channel)
 static int uwb_radio_change_channel(struct uwb_rc *rc, int channel)
 {
        int ret = 0;
+       struct device *dev = &rc->uwb_dev.dev;
+
+       dev_dbg(dev, "%s: channel = %d, rc->beaconing = %d\n", __func__,
+               channel, rc->beaconing);
 
        if (channel == -1)
                uwb_radio_channel_changed(rc, channel);