All of lore.kernel.org
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: Andrew Lunn <andrew@lunn.ch>
Cc: Jae Hyun Yoo <jae.hyun.yoo@linux.intel.com>,
	Jean Delvare <jdelvare@suse.com>,
	Jason M Biils <jason.m.bills@linux.intel.com>,
	linux-kernel@vger.kernel.org, linux-hwmon@vger.kernel.org,
	Alan Cox <alan@linux.intel.com>, Andrew Jeffery <andrew@aj.id.au>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Arnd Bergmann <arnd@arndb.de>, Joel Stanley <joel@jms.id.au>,
	Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>,
	Stef van Os <stef.van.os@prodrive-technologies.com>
Subject: Re: [v4 09/11] drivers/hwmon: Add PECI cputemp driver
Date: Mon, 21 May 2018 14:06:06 -0700	[thread overview]
Message-ID: <20180521210606.GC26644@roeck-us.net> (raw)
In-Reply-To: <20180521210158.GH8077@lunn.ch>

On Mon, May 21, 2018 at 11:01:58PM +0200, Andrew Lunn wrote:
> > >>+#if IS_ENABLED(CONFIG_X86)
> > >>+#include <asm/intel-family.h>
> > >>+#else
> > >>+#define INTEL_FAM6_HASWELL_X   0x3F
> > >>+#define INTEL_FAM6_BROADWELL_X 0x4F
> > >>+#define INTEL_FAM6_SKYLAKE_X   0x55
> > >>+#endif
> > >
> > >The entire code is very Intel specific. Why this #if instead of
> > >making the driver dependent on X86 ?
> > >
> > 
> > This code will be running on ARM kernel at this moment with a purpose
> > of monitoring remote x86 CPUs through PECI connection
> 
> How about moving what you need from asm/intel-family.h into a header
> file in include/linux/. Or move the entire header?
> 
That might be another option. The one non-option is the #if IS_ENABLED()
in the driver.

Thanks,
Guenter

  reply	other threads:[~2018-05-21 21:06 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-21 19:59 [v4 09/11] drivers/hwmon: Add PECI cputemp driver Jae Hyun Yoo
2018-05-21 20:42 ` Guenter Roeck
2018-05-21 20:50   ` Jae Hyun Yoo
2018-05-21 20:52     ` Jae Hyun Yoo
2018-05-21 21:01     ` Andrew Lunn
2018-05-21 21:06       ` Guenter Roeck [this message]
2018-05-21 21:36         ` Jae Hyun Yoo
2018-05-21 21:04     ` Guenter Roeck
2018-05-21 21:24       ` Jae Hyun Yoo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180521210606.GC26644@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=alan@linux.intel.com \
    --cc=andrew@aj.id.au \
    --cc=andrew@lunn.ch \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=arnd@arndb.de \
    --cc=jae.hyun.yoo@linux.intel.com \
    --cc=jason.m.bills@linux.intel.com \
    --cc=jdelvare@suse.com \
    --cc=joel@jms.id.au \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=miguel.ojeda.sandonis@gmail.com \
    --cc=stef.van.os@prodrive-technologies.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.