summaryrefslogtreecommitdiffstats
path: root/userspace/src/module.c
Commit message (Collapse)AuthorAge
* gpu: nvgpu: unit: deref twice in qsort callbackKonsta Holtta2018-09-18
| | | | | | | | | | | | | | | | | | The compare function for qsort takes pointers to compared elements, and our elements are already pointers so the void pointer has to be cast to a pointer pointer. Dereferencing only once would compare some data that's in the array of module pointers (or past it), not the actual data where the module pointers point to. Change-Id: I65678863eddd6fc86d4ffceb621f8123944b058d Signed-off-by: Konsta Holtta <kholtta@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1828164 Reviewed-by: svc-misra-checker <svc-misra-checker@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Alex Waterman <alexw@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* gpu: nvgpu: module.c should #include its own hdrTerje Bergstrom2018-08-11
| | | | | | | | | | | | | | | userspace/src/module.c should #include its own <unit/module.h> to get declarations for the functions defined. Change-Id: Icff647f19468607ebfb757360b83ce9f133bd5ec Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1797034 Reviewed-by: svc-misra-checker <svc-misra-checker@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Vinod Gopalakrishnakurup <vinodg@nvidia.com> Reviewed-by: Scott Long <scottl@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* gpu: nvgpu: unit: Sort unit tests by priorityAlex Waterman2018-08-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sort unit tests by their priority before running said unit tests. There are three available priorities: UNIT_PRIO_SELF_TEST UNIT_PRIO_POSIX_TEST UNIT_PRIO_NVGPU_TEST Which correspond to the types of testing expected to be run. In general unit tests should always just use UNIT_PRIO_NVGPU_TEST but in the case of tests for the POSIX API layer or the unit test framework the other two priorities are provided. The reason for this is that it doesn't make much sense to run a bunch of unit tests if the environment itself or the POSIX API layer is broken. By placing these tests at the front of the list of tests to run an engineer will easily be able to see if there are core problems versus nvgpu problems. This also lets users fine grain control of test order by adding or subtracting to UNIT_PRIO_NVGPU_TEST but one must be very careful about how they do this. JIRA NVGPU-525 Change-Id: I12a5b798e998f34e4d1168bb3696c579460f20b1 Signed-off-by: Alex Waterman <alexw@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1741953 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Konsta Holtta <kholtta@nvidia.com> Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* gpu: nvgpu: unit: Add unit testing FWAlex Waterman2018-08-10
Full documentation for this is in the unit testing confluence page. JIRA NVGPU-525 Bug 2261555 Change-Id: I463e6267eb0eb12b7313f8b275266e8faabe5ccf Signed-off-by: Alex Waterman <alexw@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1683915 GVS: Gerrit_Virtual_Submit Reviewed-by: Konsta Holtta <kholtta@nvidia.com> Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>