linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] compat: backport pm_qos_*_request
@ 2010-11-10 22:46 Felix Fietkau
  2010-11-10 22:50 ` Luis R. Rodriguez
  0 siblings, 1 reply; 3+ messages in thread
From: Felix Fietkau @ 2010-11-10 22:46 UTC (permalink / raw)
  To: linux-wireless; +Cc: Luis R. Rodriguez

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
---
--- a/include/linux/compat-2.6.36.h
+++ b/include/linux/compat-2.6.36.h
@@ -8,6 +8,7 @@
 #include <linux/usb.h>
 #include <pcmcia/cistpl.h>
 #include <pcmcia/ds.h>
+#include <linux/pm_qos_params.h>
 
 #define kparam_block_sysfs_write(a)
 #define kparam_unblock_sysfs_write(a)
@@ -58,6 +59,39 @@ static inline int pcmcia_write_config_by
 
 #define PCI_EEPROM_WIDTH_93C86   8
 
+struct pm_qos_request_list {
+	u32 qos;
+	void *request;
+};
+
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,35))
+
+#define pm_qos_add_request(_req, _class, _value) do {			\
+	(_req)->request = #_req;					\
+	(_req)->qos = _class;						\
+	pm_qos_add_requirement((_class), (_req)->request, (_value));	\
+    } while(0)
+
+#define pm_qos_update_request(_req, _value)				\
+	pm_qos_update_requirement((_req)->qos, (_req)->request, (_value))
+
+#define pm_qos_remove_request(_req)					\
+	pm_qos_remove_requirement((_req)->qos, (_req)->request)
+
+#else
+
+#define pm_qos_add_request(_req, _class, _value) do {			\
+	(_req)->request = pm_qos_add_request((_class), (_value));	\
+    } while (0)
+
+#define pm_qos_update_request(_req, _value)				\
+	pm_qos_update_request((_req)->request, (_value)
+
+#define pm_qos_remove_request(_req)					\
+	pm_qos_remove_request((_req)->request)
+
+#endif
+
 #endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,36)) */
 
 #endif /* LINUX_26_36_COMPAT_H */

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] compat: backport pm_qos_*_request
  2010-11-10 22:46 [PATCH] compat: backport pm_qos_*_request Felix Fietkau
@ 2010-11-10 22:50 ` Luis R. Rodriguez
  2010-11-10 22:52   ` Luis R. Rodriguez
  0 siblings, 1 reply; 3+ messages in thread
From: Luis R. Rodriguez @ 2010-11-10 22:50 UTC (permalink / raw)
  To: Felix Fietkau; +Cc: linux-wireless

On Wed, Nov 10, 2010 at 2:46 PM, Felix Fietkau <nbd@openwrt.org> wrote:
> Signed-off-by: Felix Fietkau <nbd@openwrt.org>

applied with some fuzz, pushed, thanks.

  Luis

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] compat: backport pm_qos_*_request
  2010-11-10 22:50 ` Luis R. Rodriguez
@ 2010-11-10 22:52   ` Luis R. Rodriguez
  0 siblings, 0 replies; 3+ messages in thread
From: Luis R. Rodriguez @ 2010-11-10 22:52 UTC (permalink / raw)
  To: Felix Fietkau, Arnaud Lacombe; +Cc: linux-wireless

On Wed, Nov 10, 2010 at 2:50 PM, Luis R. Rodriguez
<lrodriguez@atheros.com> wrote:
> On Wed, Nov 10, 2010 at 2:46 PM, Felix Fietkau <nbd@openwrt.org> wrote:
>> Signed-off-by: Felix Fietkau <nbd@openwrt.org>
>
> applied with some fuzz, pushed, thanks.

Arnaud, please

git fetch
git rebase origin/master

to ensure you get this too prior to your next submission. No need to
post all the other patches as likely it seems you only need to address
2 patches.

 Luis

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-11-10 22:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-10 22:46 [PATCH] compat: backport pm_qos_*_request Felix Fietkau
2010-11-10 22:50 ` Luis R. Rodriguez
2010-11-10 22:52   ` Luis R. Rodriguez

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).