summaryrefslogtreecommitdiff
path: root/src/libostree/ostree-kernel-args.h
Commit message (Collapse)AuthorAgeFilesLines
* tree-wide: Run clang-formatColin Walters2023-05-021-57/+28
| | | | | This is a one-time tree wide reformatting to ensure consistency going forward.
* Strip trailing whitespace on all C filesDan Nicholson2023-02-071-1/+1
| | | | | | | | My editor started following the configuration in .editorconfig and is applying this rule to many files I'm editing. Let's just get this over with and strip everything. This was done like so: git ls-files | grep '\.[ch]$' | xargs sed -ri 's/\s+$//'
* Idempotent delete operation for OstreeKernelArgsRafael Garcia Ruiz2022-11-181-0/+4
| | | | | | | ostree_kernel_args_delete_if_present checks if an argument is present in OstreeKernelArgs and delete it. Signed-off-by: Rafael Garcia Ruiz <rafael.garcia@collabora.com>
* ostree_kernel_args_contains for OstreeKernelArgsRafael Garcia Ruiz2022-11-181-0/+4
| | | | | | | | | | | Check if an argument is present in OstreeKernelArgs. This is a way to make easier idempotent append and delete operations. ostree_kernel_args_append_if_missing uses it to avoid inserting a duplicate key. Closes #2329 Signed-off-by: Rafael Garcia Ruiz <rafael.garcia@collabora.com>
* RFE: Add a hidden option to `ostree admin kargs edit-in-place` toHuijing Hei2022-06-231-0/+4
| | | | | | | | | | | update all existing deployments in place Example: $ sudo ostree admin kargs edit-in-place --append-if-missing=rw See https://github.com/ostreedev/ostree/issues/2617 This will not add duplicate key, if there is `TESTARG=VAL1` in the kernel arguments, `--append-if-missing=TESTARG=VAL2` will be ignored.
* Update FSF license notices to use URL instead of addressJoseph Marrero2021-12-071-3/+1
|
* lib/kernel-args: Store kernel args as key/value entriesRobert Fairley2019-11-071-0/+29
| | | | | | | | | | | | | Define an `OstreeKernelArgsEntry` structure, which holds both the key and the value. The kargs order array stores entries for each key/value pair, instead of just the keys. The hash table is used to locate entries, by storing entries in a pointer array for each key. The same public interface is preserved, while maintaining ordering information of each key/value pair when appending/replacing/deleting kargs. Fixes: #1859
* lib/kargs: Don't expose OstreeKernelArgs autoptr cleanup on old glibDan Nicholson2019-07-271-2/+0
| | | | | | | | | | | | | | Move the OstreeKernelArgs autoptr cleanup definition to ostree-autocleanups.h, which will only expose the definitions when building ostree or if glib is new enough. The include of ostree-kernel-args.h needs to be moved before ostree-autocleanups.h in ostree.h so that the OstreeKernelArgs type is declared when the autoptr cleanup is defined. All the places it's used already pull in libglnx.h first so that the compat macros are picked up if glib it too old during the ostree build. Closes: #1892 Approved by: jlebon
* lib/kargs: Make API public and upstream new rpm-ostree APIsAllen Bai2019-06-181-32/+81
| | | | | | | | | | | | | | | | This change makes public the current kargs API in src/libostree/ostree-kernel-args.c and adds documentations. Upstreams the new kargs API from rpm-ostree/src/libpriv/rpmostree-kargs-process.c Merges libostree_kernel_args_la_SOURCES to libostree_1_la_SOURCES in Makefile-libostree.am Upstreams tests/check/test-kargs.c from rpm-ostree. Closes: #1833 Closes: #1869 Approved by: jlebon
* tree-wide: Use autoptr for OstreeKernelArgsColin Walters2017-10-251-3/+3
| | | | | | | | Much nicer looking. Prep for more cleanup from https://github.com/projectatomic/rpm-ostree/pull/1013 Closes: #1302 Approved by: peterbaouoft
* tree-wide: Remove Emacs modelinesColin Walters2017-09-211-2/+1
| | | | | | | | | We added a `.dir-locals.el` in commit: 9a77017d87b74c5e2895cdd64ad098018929403f There's no need to have it per-file, with that people might think to add other editors, which is the wrong direction. Closes: #1206 Approved by: jlebon
* Filter bootloader supplied kernel cmdline optionsSjoerd Simons2016-11-011-0/+3
| | | | | | | | | Various bootloader add kernel commandline options dynamically, filter these out when grabbing boot options from /proc/cmdline. Specifically grub adds BOOT_IMAGE and systemd-boot adds initrd. Closes: #560 Approved by: cgwalters
* syntax-check: Remove empty lines at the end of fileGiuseppe Scrivano2015-02-021-1/+0
| | | | Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* ostree admin instutil set-kargs: make more flexibleOwen W. Taylor2014-09-261-0/+4
| | | | | | | | | | | | | Add command line arguments: --import-proc-cmdline: import values from /proc/cmdline --merge: import current values --replace=ARG=VALUE: replace value --append=ARG=VALUE: append a new argument Extra command line arguments are treated like --append=, which gives backwards compatibility. https://bugzilla.gnome.org/show_bug.cgi?id=731051
* deploy: Rework kernel arguments, add --karg-append to "admin deploy"Colin Walters2014-01-161-0/+54
The "ordered hash" code was really just for kernel arguments. And it turns out it needs to be a multihash (for e.g. multiple console= arguments). So turn the OstreeOrderedHash into OstreeKernelArgs, and move the bits to split key=value and such into there. Now we're not making this public API yet - the public OstreeSysroot just takes char **kargs. To facilitate code reuse between ostree/ and libostree/, make it a noinst libtool library. It'll be duplicated in the binary and library, but that's OK for now. We can investigate making OstreeKernelArgs public later. https://bugzilla.gnome.org/show_bug.cgi?id=721136