[Devel] [PATCH] mm: high order allocation detector
Nikita Yushchenko
nikita.yushchenko at virtuozzo.com
Tue Aug 31 16:53:53 MSK 2021
>> + return p - buf;
> Do we have any guarantee that buf will not be overflowed?
buf is a full page.
MAX_ORDER is less than 20.
This gives more than 200 bytes to print each order.
Actual print is significantly shorter.
>
>> +static int hoad_init(void)
>> +{
>> + int ret;
>> +
>> + /* To be able to generate uevents, need a kobject with kset defined.
>> + *
>> + * To avoid extra depth inside sysfs, create a kset and use it's
>> + * internal kobject, by setting it's 'kset' field to itself.
>> + */
>> + struct kset *kset = kset = kset_create_and_add("hoad", NULL, mm_kobj);
>
> extra ' = kset' ?
Indeed. Will fix now.
More information about the Devel
mailing list