diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-12-24 07:51:44 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-12-24 07:51:44 +0000 |
commit | 4da5b4b2fba02bd3e78f16828359cef79a757911 (patch) | |
tree | 326db4edaddfc20f78fb048509fd646f497e2a65 /src/nvme/log.h | |
parent | Adding upstream version 1.5. (diff) | |
download | libnvme-4da5b4b2fba02bd3e78f16828359cef79a757911.tar.xz libnvme-4da5b4b2fba02bd3e78f16828359cef79a757911.zip |
Adding upstream version 1.7.1.upstream/1.7.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/nvme/log.h')
-rw-r--r-- | src/nvme/log.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/nvme/log.h b/src/nvme/log.h index 1cf797a..7c345f6 100644 --- a/src/nvme/log.h +++ b/src/nvme/log.h @@ -35,4 +35,17 @@ */ void nvme_init_logging(nvme_root_t r, int lvl, bool log_pid, bool log_tstamp); +/** + * nvme_set_root() - Set nvme_root_t context + * @r: nvme_root_t context + * + * In order to be able to log from code paths where no root object is passed in + * via the arguments use the the default one which can be set via this call. + * When creating a new root object with @nvme_create_root the global root object + * will be set as well. This means the global root object is always pointing to + * the latest created root object. Note the first @nvme_free_tree call will reset + * the global root object. + */ +void nvme_set_root(nvme_root_t r); + #endif /* _LOG_H */ |