drivers/video/: Spelling fixes
[sfrench/cifs-2.6.git] / drivers / video / aty / radeon_pm.c
index 9a2b0d69b0ae7ebdb8bc0dac91a686e986c27f11..675abdafc2d8d047741ed3b8fdf2c0291343440c 100644 (file)
@@ -27,8 +27,6 @@
 
 #include "ati_ids.h"
 
-static void radeon_reinitialize_M10(struct radeonfb_info *rinfo);
-
 /*
  * Workarounds for bugs in PC laptops:
  * - enable D2 sleep in some IBM Thinkpads
@@ -39,6 +37,8 @@ static void radeon_reinitialize_M10(struct radeonfb_info *rinfo);
  */
 
 #if defined(CONFIG_PM) && defined(CONFIG_X86)
+static void radeon_reinitialize_M10(struct radeonfb_info *rinfo);
+
 struct radeon_device_id {
         const char *ident;                     /* (arbitrary) Name */
         const unsigned short subsystem_vendor; /* Subsystem Vendor ID */
@@ -1262,7 +1262,7 @@ static void radeon_pm_full_reset_sdram(struct radeonfb_info *rinfo)
        /* This is the code for the Aluminium PowerBooks M10 / iBooks M11 */
        if (rinfo->family == CHIP_FAMILY_RV350) {
                u32 sdram_mode_reg = rinfo->save_regs[35];
-               static u32 default_mrtable[] =
+               static const u32 default_mrtable[] =
                        { 0x21320032,
                          0x21321000, 0xa1321000, 0x21321000, 0xffffffff,
                          0x21320032, 0xa1320032, 0x21320032, 0xffffffff,
@@ -1290,7 +1290,7 @@ static void radeon_pm_full_reset_sdram(struct radeonfb_info *rinfo)
                if (rinfo->of_node != NULL) {
                        int size;
 
-                       mrtable = get_property(rinfo->of_node, "ATY,MRT", &size);
+                       mrtable = of_get_property(rinfo->of_node, "ATY,MRT", &size);
                        if (mrtable)
                                mrtable_size = size >> 2;
                        else
@@ -2561,7 +2561,7 @@ static void radeon_set_suspend(struct radeonfb_info *rinfo, int suspend)
                        pci_read_config_dword(rinfo->pdev, i * 4,
                                              &rinfo->cfg_save[i]);
 
-               /* Switch PCI power managment to D2. */
+               /* Switch PCI power management to D2. */
                pci_disable_device(rinfo->pdev);
                for (;;) {
                        pci_read_config_word(
@@ -2826,11 +2826,15 @@ void radeonfb_pm_init(struct radeonfb_info *rinfo, int dynclk, int ignore_devlis
        rinfo->pm_reg = pci_find_capability(rinfo->pdev, PCI_CAP_ID_PM);
 
        /* Enable/Disable dynamic clocks: TODO add sysfs access */
-       rinfo->dynclk = dynclk;
-       if (dynclk == 1) {
+       if (rinfo->family == CHIP_FAMILY_RS480)
+               rinfo->dynclk = -1;
+       else
+               rinfo->dynclk = dynclk;
+
+       if (rinfo->dynclk == 1) {
                radeon_pm_enable_dynamic_mode(rinfo);
                printk("radeonfb: Dynamic Clock Power Management enabled\n");
-       } else if (dynclk == 0) {
+       } else if (rinfo->dynclk == 0) {
                radeon_pm_disable_dynamic_mode(rinfo);
                printk("radeonfb: Dynamic Clock Power Management disabled\n");
        }