[Intel-gfx] [RFC/PATCH] render reclock quirks

Vedran Rodic vrodic at gmail.com
Fri Oct 30 12:04:12 CET 2009


It turns out I don't need to force reclock support, since
dual_frequency is true for my 945GM.
I've tested with latest kernel git (as of this date), and saw with
intel_gpu_top 1.0.2 that:
render clock: 400 Mhz  display clock: 320 Mhz

It's like that all the time, even when I use openarena and ring idle says 0%.

What is also strange is that  Framebuffer Compression is 100% all the time.

What is even stranger is that the only time when *display clock*
changes is when I start googleearth, where it briefly goes to 133 MHz.

Anybody knows how to explain any of this?

Thanks,
Vedran
On Tue, Oct 13, 2009 at 10:30 AM, Vedran Rodic <vrodic at gmail.com> wrote:
>
> Is reclocking supported on 945GM?
>
> Thanks
>
> On Fri, Oct 9, 2009 at 10:08 PM, Andrew Lutomirski <luto at mit.edu> wrote:
> > Add a quirk to enable render reclocking on a Thinkpad X200s.
> >
> > Signed-off-by: Andy Lutomirski <luto at mit.edu>
> > ---
> > This probably shouldn't be applied as is, but it might be useful after
> > some massaging.
> >
> > It also changes the !SUPPORTS_EDP logic, which used to disable render
> > reclocking on everything that doesn't support eDP (which is everything
> > shipping, AFAICT).
> >
> > It might be a better idea to just say "i915: VBIOS disables some power
> > saving features.  See Documentation/whatever.txt if you want to help
> > us enable it."
> >
> > --Andy
> >
> >
> > diff --git a/drivers/gpu/drm/i915/intel_bios.c
> > b/drivers/gpu/drm/i915/intel_bios.c
> > index 4337414..6a4bff5 100644
> > --- a/drivers/gpu/drm/i915/intel_bios.c
> > +++ b/drivers/gpu/drm/i915/intel_bios.c
> > @@ -29,10 +29,15 @@
> >  #include "i915_drm.h"
> >  #include "i915_drv.h"
> >  #include "intel_bios.h"
> > +#include <linux/dmi.h>
> >
> >  #define        SLAVE_ADDR1     0x70
> >  #define        SLAVE_ADDR2     0x72
> >
> > +static bool render_reclock_quirk_avail;
> > +static bool force_render_reclock;
> > +module_param(force_render_reclock, bool, 0400);
> > +
> >  static void *
> >  find_section(struct bdb_header *bdb, int section_id)
> >  {
> > @@ -351,21 +356,51 @@ parse_driver_features(struct drm_i915_private *dev_priv,
> >        struct drm_device *dev = dev_priv->dev;
> >        struct bdb_driver_features *driver;
> >
> > -       /* set default for chips without eDP */
> > -       if (!SUPPORTS_EDP(dev)) {
> > -               dev_priv->edp_support = 0;
> > -               return;
> > -       }
> > -
> > +       /* Due to quirks, we continue even if driver == NULL. */
> >        driver = find_section(bdb, BDB_DRIVER_FEATURES);
> > -       if (!driver)
> > -               return;
> >
> > -       if (driver->lvds_config == BDB_DRIVER_FEATURE_EDP)
> > +       if (driver && SUPPORTS_EDP(dev) && driver->lvds_config ==
> > BDB_DRIVER_FEATURE_EDP)
> >                dev_priv->edp_support = 1;
> > +       else
> > +               dev_priv->edp_support = 0;
> >
> > -       if (driver->dual_frequency)
> > +       if (driver && driver->dual_frequency) {
> > +               dev_priv->render_reclock_avail = true;
> > +       } else if (render_reclock_quirk_avail) {
> > +               dev_priv->render_reclock_avail = true;
> > +               printk(KERN_INFO "i915: Quirk-enabling render reclocking\n");
> > +       } else if (force_render_reclock) {
> >                dev_priv->render_reclock_avail = true;
> > +               printk(KERN_WARNING "i915: Force-enabled render reclocking.  If
> > this works, please\n"
> > +                       "  email dmesg and dmidecode output to intel-gfx at lists.freedesktop.org\n");
> > +       } else {
> > +               printk(KERN_INFO "i915: Your VBIOS does not support render reclocking.\n"
> > +                      "  Set the module parameter force_render_reclock=1 to try
> > forcing it on.");
> > +       }
> > +}
> > +
> > +static int render_reclock_quirk(const struct dmi_system_id *d)
> > +{
> > +       render_reclock_quirk_avail = true;
> > +       return 0;
> > +}
> > +
> > +static void
> > +load_quirks(void)
> > +{
> > +       static const struct dmi_system_id sysids[] = {
> > +                {
> > +                        .ident = "Lenovo X200s",
> > +                        .matches = {
> > +                                DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
> > +                                DMI_MATCH(DMI_PRODUCT_VERSION,
> > "ThinkPad X200s"),
> > +                        },
> > +                       .callback = render_reclock_quirk,
> > +                },
> > +               {}
> > +       };
> > +
> > +       dmi_check_system(sysids);
> >  }
> >
> >  /**
> > @@ -393,6 +428,8 @@ intel_init_bios(struct drm_device *dev)
> >        size_t size;
> >        int i;
> >
> > +       load_quirks();
> > +
> >        bios = pci_map_rom(pdev, &size);
> >        if (!bios)
> >                return -1;
> > _______________________________________________
> > Intel-gfx mailing list
> > Intel-gfx at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/intel-gfx
> >



More information about the Intel-gfx mailing list