From: Segher Boessenkool <segher@kernel.crashing.org>
To: linuxppc-dev@ozlabs.org
Subject: [PATCH] Fix a compile warning in powermac/feature.c
Date: Wed, 1 Aug 2007 17:41:14 +0200 [thread overview]
Message-ID: <11859828781513-git-send-email-segher@kernel.crashing.org> (raw)
Message-ID: <e774fa79388836788a57b8722999effa0392a536.1185982428.git.segher@kernel.crashing.org> (raw)
In-Reply-To: <11859828761541-git-send-email-segher@kernel.crashing.org>
...by using the pci_get API instead of the deprecated old stuff.
Signed-off-by: Segher Boessenkool <segher@kernel.crashing.org>
---
arch/powerpc/platforms/powermac/feature.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/arch/powerpc/platforms/powermac/feature.c b/arch/powerpc/platforms/powermac/feature.c
index f29705f..ba931be 100644
--- a/arch/powerpc/platforms/powermac/feature.c
+++ b/arch/powerpc/platforms/powermac/feature.c
@@ -826,13 +826,15 @@ core99_ata100_enable(struct device_node *node, long value)
if (value) {
if (pci_device_from_OF_node(node, &pbus, &pid) == 0)
- pdev = pci_find_slot(pbus, pid);
+ pdev = pci_get_bus_and_slot(pbus, pid);
if (pdev == NULL)
return 0;
rc = pci_enable_device(pdev);
+ if (rc == 0)
+ pci_set_master(pdev);
+ pci_dev_put(pdev);
if (rc)
return rc;
- pci_set_master(pdev);
}
return 0;
}
--
1.5.2.1.144.gabc40-dirty
next prev parent reply other threads:[~2007-08-01 15:41 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <576c3a210d014003c9d4b26f02a95099346f6716.1185982433.git.segher@kernel.crashing.org>
2007-08-01 15:41 ` [PATCH] Fix a compile warning in pci_32.c Segher Boessenkool
[not found] ` <e774fa79388836788a57b8722999effa0392a536.1185982428.git.segher@kernel.crashing.org>
2007-08-01 15:41 ` Segher Boessenkool [this message]
[not found] ` <4533e849af9996f5f9ce038e37bf67c4c9012a87.1185982410.git.segher@kernel.crashing.org>
2007-08-01 15:41 ` [PATCH] Replace a few #defines with empty inline functions Segher Boessenkool
[not found] ` <a2e1409163c00627f53c305f28b6d5feb530d96c.1185982424.git.segher@kernel.crashing.org>
2007-08-01 15:41 ` [PATCH] ide/ppc/pmac: Remove a few unused variables Segher Boessenkool
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=11859828781513-git-send-email-segher@kernel.crashing.org \
--to=segher@kernel.crashing.org \
--cc=linuxppc-dev@ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).