public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Miguel Botón" <mboton.lkml@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: linux-wireless@vger.kernel.org, linville@tuxdriver.com, mb@bu3sch.de
Subject: [PATCH 1/2] ssb: Add "ssb_pci_set_power_state" function
Date: Wed, 24 Oct 2007 21:31:21 +0200	[thread overview]
Message-ID: <200710242131.21959.mboton.lkml@gmail.com> (raw)

Add "ssb_pci_set_power_state" function. This allows set the power state of a 
PCI device (for example b44 ethernet device).

diff -ruN linux-2.6.23/include/linux/ssb/ssb.h 
linux-2.6.23.orig/include/linux/ssb/ssb.h
--- linux-2.6.23.orig/include/linux/ssb/ssb.h	2007-10-24 19:02:33.000000000 
+0200
+++ linux-2.6.23/include/linux/ssb/ssb.h	2007-10-24 19:49:37.000000000 +0200
@@ -402,6 +402,14 @@
 {
 	pci_unregister_driver(driver);
 }
+
+/* Set PCI device power state */
+static inline
+void ssb_pci_set_power_state(struct ssb_device *dev, pci_power_t state)
+{
+	if(dev->bus->bustype == SSB_BUSTYPE_PCI)
+		pci_set_power_state(dev->bus->host_pci, state);
+}
 #endif /* CONFIG_SSB_PCIHOST */
 
 

-- 
	Miguel Botón

             reply	other threads:[~2007-10-24 19:32 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-24 19:31 Miguel Botón [this message]
2007-10-24 20:55 ` [PATCH 1/2] ssb: Add "ssb_pci_set_power_state" function Michael Buesch
2007-11-07  2:32 ` John W. Linville

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=200710242131.21959.mboton.lkml@gmail.com \
    --to=mboton.lkml@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=mb@bu3sch.de \
    /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