Re: [PATCH v3 3/3] memory_driver: Support overriding kernel directory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2023/10/05 15:53, Mathias Krause wrote:
> Hagio-san,
> 
> On 05.10.23 04:47, HAGIO KAZUHITO(萩尾 一仁) wrote:
>> Hi Mathias,
>>
>> thank you for the patch set, looks good.
>>
>> On 2023/09/28 18:19, Mathias Krause wrote:
>>> Support compiling the module against a different kernel version than the
>>> currently running one by allowing to set either KVER or KDIR variables
>>> on the make commandline.
>>>
>>> Also modernize the makefile slightly and make use of the kernel's
>>> 'clean' target to ensure to remove all generated files.
>>>
>>> Signed-off-by: Mathias Krause <minipli@xxxxxxxxxxxxxx>
>>> ---
>>>    memory_driver/Makefile | 9 +++++++--
>>>    1 file changed, 7 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/memory_driver/Makefile b/memory_driver/Makefile
>>> index d0f3ccc912f4..61ee7c03e858 100644
>>> --- a/memory_driver/Makefile
>>> +++ b/memory_driver/Makefile
>>> @@ -8,9 +8,14 @@
>>>    # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
>>>    # GNU General Public License for more details.
>>>    #
>>> +ifneq ($(KERNELRELEASE),)
>>
>> Only one question, is this for to build the module in a customized
>> kernel tree?
> 
> It's the common pattern for external module Makefiles, making use of the
> kernel's build infrastructure (see [1]). $(KERNELRELEASE) will be set
> when this Makefile gets parsed again by kbuild, making it possible to
> distinguish its dual use and avoiding make targets to lash with kernel
> internal ones.

oh, I see.  I've not seen such a module Makefile, thank you for the 
information.  Question cleared,

Acked-by: Kazuhito Hagio <k-hagio-ab@xxxxxxx>

Thanks,
Kazu

> 
> Thanks,
> Mathias
> 
> [1]
> https://docs.kernel.org/kbuild/modules.html?highlight=kernelrelease#shared-makefile
--
Crash-utility mailing list
Crash-utility@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/crash-utility
Contribution Guidelines: https://github.com/crash-utility/crash/wiki




[Index of Archives]     [Fedora Development]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [KDE Users]     [Fedora Tools]

 

Powered by Linux