lp:kmod

Created by Registry Administrators and last modified
Get this branch:
bzr branch lp:kmod

Related bugs

Related blueprints

Branch information

Owner:
Registry Administrators
Project:
kmod
Status:
Development

Import details

Import Status: Reviewed

This branch is an import of the HEAD branch of the Git repository at git://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git.

The next import is scheduled to run .

Last successful import was .

Import started on juju-98ee42-prod-launchpad-codeimport-1 and finished taking 15 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-0 and finished taking 10 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-5 and finished taking 15 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-4 and finished taking 10 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-4 and finished taking 15 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-3 and finished taking 10 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-1 and finished taking 10 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-1 and finished taking 10 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-3 and finished taking 5 seconds — see the log
Import started on juju-98ee42-prod-launchpad-codeimport-1 and finished taking 15 seconds — see the log

Recent revisions

1998. By Rong Tao <email address hidden>

testsuite: modprobe: Add --force-{vermagic,modversion} tests

We don't have any moversion/vermagic tests. This patch add testsuite
--force-{vermagic,modversion} for modprobe.

Link: https://github.com/kmod-project/kmod/pull/344
Signed-off-by: Rong Tao <email address hidden>
Reviewed-by: Emil Velikov <email address hidden>
Signed-off-by: Lucas De Marchi <email address hidden>

1997. By Emil Velikov <email address hidden>

libkmod: update remaining function to return the error code

Rework the function signature and return the error code instead of the
stripped module. Thus we no longer explicitly set errno.

v2:
 - kmod_file_open() - use _cleanup_free_, return errno instead of ENOMEM

Reference: https://github.com/kmod-project/kmod/issues/244
Signed-off-by: Emil Velikov <email address hidden>
Link: https://github.com/kmod-project/kmod/pull/346
Signed-off-by: Lucas De Marchi <email address hidden>

1996. By Emil Velikov <email address hidden>

libkmod: return the errno from kmod_elf_new()

Rework the function signature and return the error code instead of the
stripped module. Thus we no longer explicitly set errno.

Reference: https://github.com/kmod-project/kmod/issues/244
Signed-off-by: Emil Velikov <email address hidden>
Link: https://github.com/kmod-project/kmod/pull/346
Signed-off-by: Lucas De Marchi <email address hidden>

1995. By Emil Velikov <email address hidden>

libkmod: kmod_file_get_contents() returns constant data

The function returns what is considered constant data and all the
callers handle it as such. Add the declaration to make things obvious.

Signed-off-by: Emil Velikov <email address hidden>
Link: https://github.com/kmod-project/kmod/pull/346
Signed-off-by: Lucas De Marchi <email address hidden>

1994. By Emil Velikov <email address hidden>

libkmod: enforce non-null memory in kmod_elf_new()

In practise none of our code-paths will use a NULL pointer so we might
as well enforce that. To stay aligned with the kernel behaviour update
our init_module() preload library to return EFAULT... Should we get
confused and pass NULL in the future.

Signed-off-by: Emil Velikov <email address hidden>
Link: https://github.com/kmod-project/kmod/pull/346
Signed-off-by: Lucas De Marchi <email address hidden>

1993. By Emil Velikov <email address hidden>

libkmod: return the errno from kmod_elf_strip()

Rework the function signature and return the error code instead of the
stripped module. Thus we no longer explicitly set errno.

Reference: https://github.com/kmod-project/kmod/issues/244
Signed-off-by: Emil Velikov <email address hidden>
Link: https://github.com/kmod-project/kmod/pull/346
Signed-off-by: Lucas De Marchi <email address hidden>

1992. By Emil Velikov <email address hidden>

libkmod: remove getdelim() buffer null check

As per the manual getdelim(3):
   The buffer is null-terminated and ...

Remove the local check and inline the function call. As a nice result,
we no longer set the errno and the context of feof() is obvious.

Reference: https://github.com/kmod-project/kmod/issues/244
Signed-off-by: Emil Velikov <email address hidden>
Link: https://github.com/kmod-project/kmod/pull/346
Signed-off-by: Lucas De Marchi <email address hidden>

1991. By Emil Velikov <email address hidden>

libkmod: don't set errno in strbuf_to_vector()

The function does bounds checking, allocation and copying. In the first
instance, we manually set errno (to ENOMEM?) on failure. The realloc()
call does the same, implicitly.

In practice we don't distinguish between the two failures, so we might
as well stop manually setting errno and always assume ENOMEM in the
caller.

Reference: https://github.com/kmod-project/kmod/issues/244
Signed-off-by: Emil Velikov <email address hidden>
Link: https://github.com/kmod-project/kmod/pull/346
Signed-off-by: Lucas De Marchi <email address hidden>

1990. By Emil Velikov <email address hidden>

testsuite/init-module: error out init_module() on kmod failure

Currently our wrapper init_module() will happily return success whenever
libkmod fails. While such failures are unlikely, our wrapper should also
fail. In part so it doesn't mask a potentially deeper problem and in
part because the kmod API used, will set errno... Something a normal
syscall wouldn't do AFAICT.

v2:
 - remove the respective comment

Signed-off-by: Emil Velikov <email address hidden>
Link: https://github.com/kmod-project/kmod/pull/346
Signed-off-by: Lucas De Marchi <email address hidden>

1989. By Emil Velikov <email address hidden>

libkmod: return the errno from kmod_builtin_info_init()

Change the function signature (bool -> int) and directly return the
error code. Thus we no longer need to overwrite errno.

v2:
 - return false -> return -ENAMETOOLONG

Reference: https://github.com/kmod-project/kmod/issues/244
Signed-off-by: Emil Velikov <email address hidden>
Link: https://github.com/kmod-project/kmod/pull/346
Signed-off-by: Lucas De Marchi <email address hidden>

Branch metadata

Branch format:
Branch format 7
Repository format:
Bazaar repository format 2a (needs bzr 1.16 or later)
This branch contains Public information 
Everyone can see this information.