summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau/nouveau_acpi.h
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2012-11-02 11:04:27 +1000
committerBen Skeggs <bskeggs@redhat.com>2012-11-29 09:57:59 +1000
commitc839d748bdaa4f373368abeef3efc18e21e78313 (patch)
tree7c677be1bbd382f7af70c18285e9812fb8e4ea8a /drivers/gpu/drm/nouveau/nouveau_acpi.h
parentbf2c886a857dcf61f2354796a8858a230f2737fa (diff)
downloadop-kernel-dev-c839d748bdaa4f373368abeef3efc18e21e78313.zip
op-kernel-dev-c839d748bdaa4f373368abeef3efc18e21e78313.tar.gz
drm/nouveau: Add interface to detect optimus and v1 support
This is required to decide if we can auto-powerdown and how to implement it. Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_acpi.h')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_acpi.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_acpi.h b/drivers/gpu/drm/nouveau/nouveau_acpi.h
index 08af677..d0da230 100644
--- a/drivers/gpu/drm/nouveau/nouveau_acpi.h
+++ b/drivers/gpu/drm/nouveau/nouveau_acpi.h
@@ -4,6 +4,8 @@
#define ROM_BIOS_PAGE 4096
#if defined(CONFIG_ACPI)
+bool nouveau_is_optimus(void);
+bool nouveau_is_v1_dsm(void);
void nouveau_register_dsm_handler(void);
void nouveau_unregister_dsm_handler(void);
void nouveau_switcheroo_optimus_dsm(void);
@@ -11,6 +13,8 @@ int nouveau_acpi_get_bios_chunk(uint8_t *bios, int offset, int len);
bool nouveau_acpi_rom_supported(struct pci_dev *pdev);
void *nouveau_acpi_edid(struct drm_device *, struct drm_connector *);
#else
+static inline bool nouveau_is_optimus(void) { return false; };
+static inline bool nouveau_is_v1_dsm(void) { return false; };
static inline void nouveau_register_dsm_handler(void) {}
static inline void nouveau_unregister_dsm_handler(void) {}
static inline void nouveau_switcheroo_optimus_dsm(void) {}
OpenPOWER on IntegriCloud