From: Alex Deucher Subject: Re: Radeon hwmon driver Date: Thu, 11 Feb 2010 10:09:42 -0500 Message-ID: References: <20100207231231.GA5065@raptus.dandreoli.com> <20100210211329.GA4512@raptus.dandreoli.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.sourceforge.net To: Domenico Andreoli Cc: dri-devel@lists.sourceforge.net List-Id: dri-devel@lists.freedesktop.org On Thu, Feb 11, 2010 at 7:12 AM, Domenico Andreoli wrote: > On Wed, Feb 10, 2010 at 11:06 PM, Alex Deucher wr= ote: >> On Wed, Feb 10, 2010 at 4:13 PM, Domenico Andreoli = wrote: >>> On Mon, Feb 08, 2010 at 01:32:33AM -0500, Alex Deucher wrote: >>>> On Sun, Feb 7, 2010 at 6:12 PM, Domenico Andreoli wrote: >>>> > Hi all, >>>> > >>>> > =A0I'd like to write a hwmon driver for the Radeon GPUs. I made a qu= ick >>>> > search in the M56 and M76 register references on AMD's site but didn= 't >>>> > find anything. I then wrote to gpudriverdevsupport@amd.com and now I= 'm >>>> > waiting for some response. In the meanwhile, has anybody of you seen >>>> > anything related to this task while working at the graphic drivers? >>>> > >>>> > Supposing I will find the missing info, I see the first problem. I >>>> > guess the hwmon registers are in the address space mapped by the DRM >>>> > driver. Surely I could make a patch but then the radeon's hwmon supp= ort >>>> > would depend on the DRM driver. And if one wants the hwmon support >>>> > but doesn't want DRM? Would she need/use a different hwmon driver, >>>> > maybe thank to some Kconfig trick? Any advice? >>>> >>>> The thermal and fan chips are generally 3rd party chips connected via >>>> i2c. =A0I think most of the chips used have hwmon drivers already. =A0= You >>>> can look up the chip and i2c address in the power tables in the bios. >>>> See the PowerPlayInfo table definitions in atombios.h. =A0I've started >>>> work on cleaning up the radeon i2c buses for external use in the >>>> drm-radeon-testing branch of Dave's drm tree: >>>> http://git.kernel.org/?p=3Dlinux/kernel/git/airlied/drm-2.6.git;a=3Dsu= mmary >>> >>> I have a question: once the i2c cleaning is completed, every known >>> sensor hooked to it is available to the user-space. Would have any >>> sense that I worked on a hwmon wrapper in the kernel? Which duties >>> would still require the mighty kernel? >> >> You can just load the hwmon driver for the chip in question and >> interface with it via the hwmon API. =A0It would just be hanging off an >> i2c bus on the GPU rather than an i2c bus on the motherboard, > > That's it, nothing special is left to allow the use those i2c sensors from > user space, once you finished the cleanup of radeon's i2c. Indeed > i2cdetect already sees the newly available i2c buses. If I'm wrong > then I am still missing something. Thank you. > That should be it. Alex ---------------------------------------------------------------------------= --- SOLARIS 10 is the OS for Data Centers - provides features such as DTrace, Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW http://p.sf.net/sfu/solaris-dev2dev --