| Submitter | Asbjoern Sloth Toennesen |
|---|---|
| Date | Nov. 10, 2011, 4:10 p.m. |
| Message ID | <1320941426-1100-1-git-send-email-asbjorn@asbjorn.biz> |
| Download | mbox | patch |
| Permalink | /patch/124927/ |
| State | Not Applicable |
| Delegated to: | David Miller |
| Headers | show |
Comments
On 11/10/2011 08:10 AM, Asbjoern Sloth Toennesen wrote: > 3.2-rc1 and Linus' tree at 5e442a49, fails to compile, > with CONFIG_SFF defined without CONFIG_ATA_BMDMA. > > The error was introduced by: > [ c2036033 ] libata: reduce ata_pci_[sff,bmdma]_init_one() size > > Note this patch have only been compile tested. > > Signed-off-by: Asbjoern Sloth Toennesen <asbjorn@asbjorn.biz> Reported-by: Randy Dunlap <rdunlap@xenotime.net> Acked-by: Randy Dunlap <rdunlap@xenotime.net> Thanks. > --- > drivers/ata/libata-sff.c | 4 ++++ > 1 files changed, 4 insertions(+), 0 deletions(-) > > diff --git a/drivers/ata/libata-sff.c b/drivers/ata/libata-sff.c > index 63d5327..82b1237 100644 > --- a/drivers/ata/libata-sff.c > +++ b/drivers/ata/libata-sff.c > @@ -2533,10 +2533,12 @@ static int ata_pci_init_one(struct pci_dev *pdev, > if (rc) > goto out; > > + #ifdef CONFIG_ATA_BMDMA > if (bmdma) > /* prepare and activate BMDMA host */ > rc = ata_pci_bmdma_prepare_host(pdev, ppi, &host); > else > + #endif /* CONFIG_ATA_BMDMA */ > /* prepare and activate SFF host */ > rc = ata_pci_sff_prepare_host(pdev, ppi, &host); > if (rc) > @@ -2544,10 +2546,12 @@ static int ata_pci_init_one(struct pci_dev *pdev, > host->private_data = host_priv; > host->flags |= hflags; > > + #ifdef CONFIG_ATA_BMDMA > if (bmdma) { > pci_set_master(pdev); > rc = ata_pci_sff_activate_host(host, ata_bmdma_interrupt, sht); > } else > + #endif /* CONFIG_ATA_BMDMA */ > rc = ata_pci_sff_activate_host(host, ata_sff_interrupt, sht); > out: > if (rc == 0)
Patch
diff --git a/drivers/ata/libata-sff.c b/drivers/ata/libata-sff.c index 63d5327..82b1237 100644 --- a/drivers/ata/libata-sff.c +++ b/drivers/ata/libata-sff.c @@ -2533,10 +2533,12 @@ static int ata_pci_init_one(struct pci_dev *pdev, if (rc) goto out; + #ifdef CONFIG_ATA_BMDMA if (bmdma) /* prepare and activate BMDMA host */ rc = ata_pci_bmdma_prepare_host(pdev, ppi, &host); else + #endif /* CONFIG_ATA_BMDMA */ /* prepare and activate SFF host */ rc = ata_pci_sff_prepare_host(pdev, ppi, &host); if (rc) @@ -2544,10 +2546,12 @@ static int ata_pci_init_one(struct pci_dev *pdev, host->private_data = host_priv; host->flags |= hflags; + #ifdef CONFIG_ATA_BMDMA if (bmdma) { pci_set_master(pdev); rc = ata_pci_sff_activate_host(host, ata_bmdma_interrupt, sht); } else + #endif /* CONFIG_ATA_BMDMA */ rc = ata_pci_sff_activate_host(host, ata_sff_interrupt, sht); out: if (rc == 0)
3.2-rc1 and Linus' tree at 5e442a49, fails to compile, with CONFIG_SFF defined without CONFIG_ATA_BMDMA. The error was introduced by: [ c2036033 ] libata: reduce ata_pci_[sff,bmdma]_init_one() size Note this patch have only been compile tested. Signed-off-by: Asbjoern Sloth Toennesen <asbjorn@asbjorn.biz> --- drivers/ata/libata-sff.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-)