Le 26/01/2022 à 22:36, Mike Rapoport a écrit :
> On Mon, Jan 24, 2022 at 09:22:15AM +, Christophe Leroy wrote:
>> within_module_core() and within_module_init() are doing the exact same
>> test, one on core_layout, the second on init_layout.
>>
>> In preparation of increasing the complexity
Le 24/01/2022 à 13:32, Christoph Hellwig a écrit :
> On Mon, Jan 24, 2022 at 09:22:15AM +, Christophe Leroy wrote:
>> +static inline bool within_range(unsigned long addr, void *base, unsigned
>> int size)
>
> Please avoid the overly long line.
>
> .. But given that this function only has
On Mon, Jan 24, 2022 at 09:22:15AM +, Christophe Leroy wrote:
> within_module_core() and within_module_init() are doing the exact same
> test, one on core_layout, the second on init_layout.
>
> In preparation of increasing the complexity of that verification,
> refactor it into a single
Le 24/01/2022 à 13:32, Christoph Hellwig a écrit :
> On Mon, Jan 24, 2022 at 09:22:15AM +, Christophe Leroy wrote:
>> +static inline bool within_range(unsigned long addr, void *base, unsigned
>> int size)
>
> Please avoid the overly long line.
>
> .. But given that this function only has
On Mon, Jan 24, 2022 at 09:22:15AM +, Christophe Leroy wrote:
> +static inline bool within_range(unsigned long addr, void *base, unsigned int
> size)
Please avoid the overly long line.
.. But given that this function only has a single caller I see no
point in factoring it out anyway.
within_module_core() and within_module_init() are doing the exact same
test, one on core_layout, the second on init_layout.
In preparation of increasing the complexity of that verification,
refactor it into a single function called within_module_layout().
Signed-off-by: Christophe Leroy
---