Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 102041
b: refs/heads/master
c: 25d39c3
h: refs/heads/master
i:
  102039: b13f1a6
v: v3
  • Loading branch information
Bjorn Helgaas authored and Andi Kleen committed Jul 16, 2008
1 parent 26ec552 commit a703f9f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 27 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5acf91415799025410cc0d13101340d352f34c89
refs/heads/master: 25d39c39d82d062f4be685146abd054a3bafdf12
34 changes: 8 additions & 26 deletions trunk/drivers/pnp/resource.c
Original file line number Diff line number Diff line change
Expand Up @@ -537,15 +537,10 @@ struct pnp_resource *pnp_add_irq_resource(struct pnp_dev *dev, int irq,
{
struct pnp_resource *pnp_res;
struct resource *res;
static unsigned char warned;

pnp_res = pnp_new_resource(dev);
if (!pnp_res) {
if (!warned) {
dev_err(&dev->dev, "can't add resource for IRQ %d\n",
irq);
warned = 1;
}
dev_err(&dev->dev, "can't add resource for IRQ %d\n", irq);
return NULL;
}

Expand All @@ -563,15 +558,10 @@ struct pnp_resource *pnp_add_dma_resource(struct pnp_dev *dev, int dma,
{
struct pnp_resource *pnp_res;
struct resource *res;
static unsigned char warned;

pnp_res = pnp_new_resource(dev);
if (!pnp_res) {
if (!warned) {
dev_err(&dev->dev, "can't add resource for DMA %d\n",
dma);
warned = 1;
}
dev_err(&dev->dev, "can't add resource for DMA %d\n", dma);
return NULL;
}

Expand All @@ -590,16 +580,12 @@ struct pnp_resource *pnp_add_io_resource(struct pnp_dev *dev,
{
struct pnp_resource *pnp_res;
struct resource *res;
static unsigned char warned;

pnp_res = pnp_new_resource(dev);
if (!pnp_res) {
if (!warned) {
dev_err(&dev->dev, "can't add resource for IO "
"%#llx-%#llx\n",(unsigned long long) start,
(unsigned long long) end);
warned = 1;
}
dev_err(&dev->dev, "can't add resource for IO %#llx-%#llx\n",
(unsigned long long) start,
(unsigned long long) end);
return NULL;
}

Expand All @@ -619,16 +605,12 @@ struct pnp_resource *pnp_add_mem_resource(struct pnp_dev *dev,
{
struct pnp_resource *pnp_res;
struct resource *res;
static unsigned char warned;

pnp_res = pnp_new_resource(dev);
if (!pnp_res) {
if (!warned) {
dev_err(&dev->dev, "can't add resource for MEM "
"%#llx-%#llx\n",(unsigned long long) start,
(unsigned long long) end);
warned = 1;
}
dev_err(&dev->dev, "can't add resource for MEM %#llx-%#llx\n",
(unsigned long long) start,
(unsigned long long) end);
return NULL;
}

Expand Down

0 comments on commit a703f9f

Please sign in to comment.