Rename WARN() to WARNING() to clear the namespace

We want to use WARN() as a variant of WARN_ON(), however a few drivers are
using WARN() internally.  This patch renames these to WARNING() to avoid the
namespace clash.  A few cases were defining but not using the thing, for those
cases I just deleted the definition.

Signed-off-by: Arjan van de Ven <[email protected]>
Acked-by: Greg KH <[email protected]>
Cc: Karsten Keil <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
Arjan van de Ven 2008-07-25 01:45:52 -07:00 • committed by Linus Torvalds
commit b6c6393700
28 changed files with 48 additions and 55 deletions

View file

@ -171,7 +171,7 @@ struct at91_request {
#endif
#define ERR(stuff...) pr_err("udc: " stuff)
#define WARN(stuff...) pr_warning("udc: " stuff)
#define WARNING(stuff...) pr_warning("udc: " stuff)
#define INFO(stuff...) pr_info("udc: " stuff)
#define DBG(stuff...) pr_debug("udc: " stuff)

View file

@ -170,7 +170,7 @@ static int __init cdc_bind(struct usb_composite_dev *cdev)
* but if the controller isn't recognized at all then
* that assumption is a bit more likely to be wrong.
*/
WARN(cdev, "controller '%s' not recognized; trying %s\n",
WARNING(cdev, "controller '%s' not recognized; trying %s\n",
gadget->name,
cdc_config_driver.label);
device_desc.bcdDevice =

View file

@ -293,7 +293,7 @@ static int __init eth_bind(struct usb_composite_dev *cdev)
* but if the controller isn't recognized at all then
* that assumption is a bit more likely to be wrong.
*/
WARN(cdev, "controller '%s' not recognized; trying %s\n",
WARNING(cdev, "controller '%s' not recognized; trying %s\n",
gadget->name,
eth_config_driver.label);
device_desc.bcdDevice =

View file

@ -308,7 +308,7 @@ MODULE_LICENSE("Dual BSD/GPL");
dev_vdbg(&(d)->gadget->dev , fmt , ## args)
#define ERROR(d, fmt, args...) \
dev_err(&(d)->gadget->dev , fmt , ## args)
#define WARN(d, fmt, args...) \
#define WARNING(d, fmt, args...) \
dev_warn(&(d)->gadget->dev , fmt , ## args)
#define INFO(d, fmt, args...) \
dev_info(&(d)->gadget->dev , fmt , ## args)
@ -1091,7 +1091,7 @@ static int ep0_queue(struct fsg_dev *fsg)
if (rc != 0 && rc != -ESHUTDOWN) {
/* We can't do much more than wait for a reset */
WARN(fsg, "error in submission: %s --> %d\n",
WARNING(fsg, "error in submission: %s --> %d\n",
fsg->ep0->name, rc);
}
return rc;
@ -1227,7 +1227,7 @@ static void received_cbi_adsc(struct fsg_dev *fsg, struct fsg_buffhd *bh)
/* Save the command for later */
if (fsg->cbbuf_cmnd_size)
WARN(fsg, "CB[I] overwriting previous command\n");
WARNING(fsg, "CB[I] overwriting previous command\n");
fsg->cbbuf_cmnd_size = req->actual;
memcpy(fsg->cbbuf_cmnd, req->buf, fsg->cbbuf_cmnd_size);
@ -1506,7 +1506,7 @@ static void start_transfer(struct fsg_dev *fsg, struct usb_ep *ep,
* submissions if DMA is enabled. */
if (rc != -ESHUTDOWN && !(rc == -EOPNOTSUPP &&
req->length == 0))
WARN(fsg, "error in submission: %s --> %d\n",
WARNING(fsg, "error in submission: %s --> %d\n",
ep->name, rc);
}
}
@ -2294,7 +2294,7 @@ static int halt_bulk_in_endpoint(struct fsg_dev *fsg)
VDBG(fsg, "delayed bulk-in endpoint halt\n");
while (rc != 0) {
if (rc != -EAGAIN) {
WARN(fsg, "usb_ep_set_halt -> %d\n", rc);
WARNING(fsg, "usb_ep_set_halt -> %d\n", rc);
rc = 0;
break;
}
@ -2317,7 +2317,7 @@ static int wedge_bulk_in_endpoint(struct fsg_dev *fsg)
VDBG(fsg, "delayed bulk-in endpoint wedge\n");
while (rc != 0) {
if (rc != -EAGAIN) {
WARN(fsg, "usb_ep_set_wedge -> %d\n", rc);
WARNING(fsg, "usb_ep_set_wedge -> %d\n", rc);
rc = 0;
break;
}
@ -3755,7 +3755,7 @@ static int __init check_parameters(struct fsg_dev *fsg)
if (gcnum >= 0)
mod_data.release = 0x0300 + gcnum;
else {
WARN(fsg, "controller '%s' not recognized\n",
WARNING(fsg, "controller '%s' not recognized\n",
fsg->gadget->name);
mod_data.release = 0x0399;
}

View file

@ -1538,7 +1538,7 @@ static void dtd_complete_irq(struct fsl_udc *udc)
/* If the ep is configured */
if (curr_ep->name == NULL) {
WARN("Invalid EP?");
WARNING("Invalid EP?");
continue;
}

View file

@ -552,7 +552,7 @@ static void dump_msg(const char *label, const u8 * buf, unsigned int length)
#endif
#define ERR(stuff...) pr_err("udc: " stuff)
#define WARN(stuff...) pr_warning("udc: " stuff)
#define WARNING(stuff...) pr_warning("udc: " stuff)
#define INFO(stuff...) pr_info("udc: " stuff)
/*-------------------------------------------------------------------------*/

View file

@ -138,8 +138,6 @@ static void gmidi_transmit(struct gmidi_device* dev, struct usb_request* req);
dev_vdbg(&(d)->gadget->dev , fmt , ## args)
#define ERROR(d, fmt, args...) \
dev_err(&(d)->gadget->dev , fmt , ## args)
#define WARN(d, fmt, args...) \
dev_warn(&(d)->gadget->dev , fmt , ## args)
#define INFO(d, fmt, args...) \
dev_info(&(d)->gadget->dev , fmt , ## args)

View file

@ -1768,7 +1768,7 @@ static int goku_probe(struct pci_dev *pdev, const struct pci_device_id *id)
* usb_gadget_driver_{register,unregister}() must change.
*/
if (the_controller) {
WARN(dev, "ignoring %s\n", pci_name(pdev));
WARNING(dev, "ignoring %s\n", pci_name(pdev));
return -EBUSY;
}
if (!pdev->irq) {

View file

@ -285,7 +285,7 @@ struct goku_udc {
#define ERROR(dev,fmt,args...) \
xprintk(dev , KERN_ERR , fmt , ## args)
#define WARN(dev,fmt,args...) \
#define WARNING(dev,fmt,args...) \
xprintk(dev , KERN_WARNING , fmt , ## args)
#define INFO(dev,fmt,args...) \
xprintk(dev , KERN_INFO , fmt , ## args)

View file

@ -262,8 +262,6 @@ static const char *CHIP;
#define ERROR(dev,fmt,args...) \
xprintk(dev , KERN_ERR , fmt , ## args)
#define WARN(dev,fmt,args...) \
xprintk(dev , KERN_WARNING , fmt , ## args)
#define INFO(dev,fmt,args...) \
xprintk(dev , KERN_INFO , fmt , ## args)

View file

@ -1007,7 +1007,7 @@ static void scan_dma_completions (struct net2280_ep *ep)
* 0122, and 0124; not all cases trigger the warning.
*/
if ((tmp & (1 << NAK_OUT_PACKETS)) == 0) {
WARN (ep->dev, "%s lost packet sync!\n",
WARNING (ep->dev, "%s lost packet sync!\n",
ep->ep.name);
req->req.status = -EOVERFLOW;
} else if ((tmp = readl (&ep->regs->ep_avail)) != 0) {

View file

@ -272,7 +272,7 @@ static inline void net2280_led_shutdown (struct net2280 *dev)
#define ERROR(dev,fmt,args...) \
xprintk(dev , KERN_ERR , fmt , ## args)
#define WARN(dev,fmt,args...) \
#define WARNING(dev,fmt,args...) \
xprintk(dev , KERN_WARNING , fmt , ## args)
#define INFO(dev,fmt,args...) \
xprintk(dev , KERN_INFO , fmt , ## args)

View file

@ -1120,7 +1120,7 @@ static int omap_ep_set_halt(struct usb_ep *_ep, int value)
status = -EINVAL;
else if (value) {
if (ep->udc->ep0_set_config) {
WARN("error changing config?\n");
WARNING("error changing config?\n");
omap_writew(UDC_CLR_CFG, UDC_SYSCON2);
}
omap_writew(UDC_STALL_CMD, UDC_SYSCON2);
@ -1764,7 +1764,7 @@ do_stall:
u.r.bRequestType, u.r.bRequest, status);
if (udc->ep0_set_config) {
if (udc->ep0_reset_config)
WARN("error resetting config?\n");
WARNING("error resetting config?\n");
else
omap_writew(UDC_CLR_CFG, UDC_SYSCON2);
}
@ -3076,7 +3076,7 @@ static int omap_udc_suspend(struct platform_device *dev, pm_message_t message)
* which would prevent entry to deep sleep...
*/
if ((devstat & UDC_ATT) != 0 && (devstat & UDC_SUS) == 0) {
WARN("session active; suspend requires disconnect\n");
WARNING("session active; suspend requires disconnect\n");
omap_pullup(&udc->gadget, 0);
}

View file

@ -188,7 +188,7 @@ struct omap_udc {
#endif
#define ERR(stuff...) pr_err("udc: " stuff)
#define WARN(stuff...) pr_warning("udc: " stuff)
#define WARNING(stuff...) pr_warning("udc: " stuff)
#define INFO(stuff...) pr_info("udc: " stuff)
#define DBG(stuff...) pr_debug("udc: " stuff)

View file

@ -179,7 +179,7 @@ module_param(qlen, uint, S_IRUGO|S_IWUSR);
#define ERROR(dev, fmt, args...) \
xprintk(dev, KERN_ERR, fmt, ## args)
#define WARN(dev, fmt, args...) \
#define WARNING(dev, fmt, args...) \
xprintk(dev, KERN_WARNING, fmt, ## args)
#define INFO(dev, fmt, args...) \
xprintk(dev, KERN_INFO, fmt, ## args)

View file

@ -342,7 +342,7 @@ pxa25x_ep_free_request (struct usb_ep *_ep, struct usb_request *_req)
struct pxa25x_request *req;
req = container_of (_req, struct pxa25x_request, req);
WARN_ON (!list_empty (&req->queue));
WARN_ON(!list_empty (&req->queue));
kfree(req);
}
@ -1556,7 +1556,7 @@ config_change:
* tell us about config change events,
* so later ones may fail...
*/
WARN("config change %02x fail %d?\n",
WARNING("config change %02x fail %d?\n",
u.r.bRequest, i);
return;
/* TODO experiment: if has_cfr,
@ -2330,7 +2330,7 @@ static int pxa25x_udc_suspend(struct platform_device *dev, pm_message_t state)
unsigned long flags;
if (!udc->mach->gpio_pullup && !udc->mach->udc_command)
WARN("USB host won't detect disconnect!\n");
WARNING("USB host won't detect disconnect!\n");
udc->suspended = 1;
local_irq_save(flags);

View file

@ -259,7 +259,7 @@ dump_state(struct pxa25x_udc *dev)
#define DBG(lvl, stuff...) do{if ((lvl) <= UDC_DEBUG) DMSG(stuff);}while(0)
#define ERR(stuff...) pr_err("udc: " stuff)
#define WARN(stuff...) pr_warning("udc: " stuff)
#define WARNING(stuff...) pr_warning("udc: " stuff)
#define INFO(stuff...) pr_info("udc: " stuff)

View file

@ -116,7 +116,6 @@ static inline int qlen(struct usb_gadget *gadget)
#undef DBG
#undef VDBG
#undef ERROR
#undef WARN
#undef INFO
#define xprintk(d, level, fmt, args...) \
@ -140,8 +139,6 @@ static inline int qlen(struct usb_gadget *gadget)
#define ERROR(dev, fmt, args...) \
xprintk(dev , KERN_ERR , fmt , ## args)
#define WARN(dev, fmt, args...) \
xprintk(dev , KERN_WARNING , fmt , ## args)
#define INFO(dev, fmt, args...) \
xprintk(dev , KERN_INFO , fmt , ## args)

View file

@ -882,7 +882,7 @@ static void isp116x_endpoint_disable(struct usb_hcd *hcd,
for (i = 0; i < 100 && !list_empty(&hep->urb_list); i++)
msleep(3);
if (!list_empty(&hep->urb_list))
WARN("ep %p not empty?\n", ep);
WARNING("ep %p not empty?\n", ep);
kfree(ep);
hep->hcpriv = NULL;

View file

@ -338,7 +338,7 @@ struct isp116x_ep {
#endif
#define ERR(stuff...) printk(KERN_ERR "116x: " stuff)
#define WARN(stuff...) printk(KERN_WARNING "116x: " stuff)
#define WARNING(stuff...) printk(KERN_WARNING "116x: " stuff)
#define INFO(stuff...) printk(KERN_INFO "116x: " stuff)
/* ------------------------------------------------- */

View file

@ -1026,7 +1026,7 @@ sl811h_endpoint_disable(struct usb_hcd *hcd, struct usb_host_endpoint *hep)
if (!list_empty(&hep->urb_list))
msleep(3);
if (!list_empty(&hep->urb_list))
WARN("ep %p not empty?\n", ep);
WARNING("ep %p not empty?\n", ep);
kfree(ep);
hep->hcpriv = NULL;

View file

@ -261,6 +261,6 @@ sl811_read_buf(struct sl811 *sl811, int addr, void *buf, size_t count)
#endif
#define ERR(stuff...) printk(KERN_ERR "sl811: " stuff)
#define WARN(stuff...) printk(KERN_WARNING "sl811: " stuff)
#define WARNING(stuff...) printk(KERN_WARNING "sl811: " stuff)
#define INFO(stuff...) printk(KERN_INFO "sl811: " stuff)

View file

@ -81,7 +81,7 @@ static struct usb_device *testdev_to_usbdev (struct usbtest_dev *test)
#define ERROR(tdev, fmt, args...) \
dev_err(&(tdev)->intf->dev , fmt , ## args)
#define WARN(tdev, fmt, args...) \
#define WARNING(tdev, fmt, args...) \
dev_warn(&(tdev)->intf->dev , fmt , ## args)
/*-------------------------------------------------------------------------*/
@ -1946,7 +1946,7 @@ usbtest_probe (struct usb_interface *intf, const struct usb_device_id *id)
status = get_endpoints (dev, intf);
if (status < 0) {
WARN(dev, "couldn't get endpoints, %d\n",
WARNING(dev, "couldn't get endpoints, %d\n",
status);
return status;
}