Source-Changes-D archive

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

Re: CVS commit: src/tests/modules



I have got no opinion. Please rearrange the directories as needed.

While there, it would be good to implement modctl(MODCTL_MODSTAT,
&modstat) to check whether a specific module is loaded into the kernel
and retrieve modstat_t describing it.

modstat_t m;
strlcpy(&m.ms_name, "haxm", MAXMODNAME);
if (modctl(MODCTL_MODSTAT, &modstat) == -1)
    err(EXIT_FAILURE, "modctl: haxm");

I have got use-cases for these checks and I envision their wider usage
in future. We already have 3 use-cases in ATF tests.

On 22.02.2020 04:41, Paul Goyette wrote:
> OK, I over-reacted and didn't completely read the original commit
> message.
> 
> The t_builtin.c stuff is indeed a test-of-module-functionality
> so it does belong here.
> 
> But some of the other stuff here does not belong, such as the
> threadpool, fetchstore, and kcov stuff.  As far as I can see,
> those all belong somewhere else, probably in the tests/sys/...
> hierarchy.
> 
> Anyway, my apologies for over-reacting to this commit.  And
> thanks to riastradh@ for pointing this out (on IRC).
> 
> 
> 
> On Fri, 21 Feb 2020, Paul Goyette wrote:
> 
>> Really, the tests/modules directory should be only used for tests-that-
>> relate-to-module-functionality.  It should NOT be used for modules-
>> that-support-tests-of-other-functionality.
>>
>> In the future, please do not put support modules here;  put them in the
>> samae place as the tests that they support.
>>
>>
>> On Sat, 22 Feb 2020, Kamil Rytarowski wrote:
>>
>>> Module Name:    src
>>> Committed By:    kamil
>>> Date:        Sat Feb 22 00:18:55 UTC 2020
>>>
>>> Modified Files:
>>>     src/tests/modules: t_builtin.c
>>>
>>> Log Message:
>>> Avoid undefined behavior in disabledstat
>>>
>>> t_builtin.c:174:16, member access within misaligned address
>>> 0x741271c25004
>>> for type 'struct modstat_t'
>>>
>>> t_builtin.c:175:4, member access within misaligned address
>>> 0x741271c251c4
>>> for type 'struct modstat_t'
>>>
>>>
>>> To generate a diff of this commit:
>>> cvs rdiff -u -r1.4 -r1.5 src/tests/modules/t_builtin.c
>>>
>>> Please note that diffs are not public domain; they are subject to the
>>> copyright notices on the relevant files.
>>>
>>>
>>> !DSPAM:5e5073af66043393299806!
>>>
>>>
>>
>> +--------------------+--------------------------+-----------------------+
>> | Paul Goyette       | PGP Key fingerprint:     | E-mail addresses:     |
>> | (Retired)          | FA29 0E3B 35AF E8AE 6651 | paul%whooppee.com@localhost     |
>> | Software Developer | 0786 F758 55DE 53BA 7731 | pgoyette%netbsd.org@localhost   |
>> +--------------------+--------------------------+-----------------------+
>>
> 
> +--------------------+--------------------------+-----------------------+
> | Paul Goyette       | PGP Key fingerprint:     | E-mail addresses:     |
> | (Retired)          | FA29 0E3B 35AF E8AE 6651 | paul%whooppee.com@localhost     |
> | Software Developer | 0786 F758 55DE 53BA 7731 | pgoyette%netbsd.org@localhost   |
> +--------------------+--------------------------+-----------------------+


Attachment: signature.asc
Description: OpenPGP digital signature



Home | Main Index | Thread Index | Old Index