Re: [PATCH 2/2] tg3: fix build-time dependency withIS_DEPENDENCY_SATISFIED()

From: Paul Gortmaker
Date: Mon Oct 01 2012 - 12:11:16 EST


[[PATCH 2/2] tg3: fix build-time dependency with IS_DEPENDENCY_SATISFIED()] On 01/10/2012 (Mon 14:21) Anisse Astier wrote:

> When CONFIG_TIGON3=y and CONFIG_HWMON=y, we will get this error:
> LD init/built-in.o
> drivers/built-in.o: In function `tg3_hwmon_open':
> tg3.c:(.text+0xc1d12): undefined reference to `hwmon_device_register'
> drivers/built-in.o: In function `tg3_close':
> tg3.c:(.text+0xc2e7f): undefined reference to `hwmon_device_unregister'
> make: *** [vmlinux] Error 1
>
> Use the new IS_DEPENDENCY_SATISFIED() facility to solve this problem.

Even though my fingerprints may be on IS_ENABLED, I'm not a fan of using
it (or things like this extension) all over the place for #ifdef blocks
that can be avoided some other clean way.

How about we just fix this the way Dave suggested a few months ago?

P.

--