module/gpt: remove legacy config support
This patch removes legacy config support in GPT bdev module. Please note that disabling probing only for GPT partition does not have a corresponding RPC. Similar functionality is possible for all bdev modules at once via `bdev_set_options --disable-auto-examine` RPC then followed by `bdev_examine` RPC for particular bdev. Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> Change-Id: I9a106b3dc0953166264b11c2e95c4433163fcd3c Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4624 Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Paul Luse <paul.e.luse@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
aed3d21eca
commit
ccdbe656be
@ -14,6 +14,12 @@ removed between a call to get its structure based on a name and actually opennin
|
|||||||
|
|
||||||
Updated DPDK submodule to DPDK 20.08.
|
Updated DPDK submodule to DPDK 20.08.
|
||||||
|
|
||||||
|
### gpt
|
||||||
|
|
||||||
|
Removed option to disable GPT probing via legacy configuration. Please use generic
|
||||||
|
bdev functionality to replicate the behavior. See `bdev_set_options --disable-auto-examine`
|
||||||
|
and `bdev_examine` RPC.
|
||||||
|
|
||||||
### intel-ipsec-mb
|
### intel-ipsec-mb
|
||||||
|
|
||||||
Updated intel-ipsec-mb submodule to v0.54
|
Updated intel-ipsec-mb submodule to v0.54
|
||||||
|
@ -123,7 +123,7 @@ DEPDIRS-sock_posix := log sock util
|
|||||||
DEPDIRS-sock_uring := log sock util
|
DEPDIRS-sock_uring := log sock util
|
||||||
|
|
||||||
# module/bdev
|
# module/bdev
|
||||||
DEPDIRS-bdev_gpt := bdev conf json log thread util
|
DEPDIRS-bdev_gpt := bdev json log thread util
|
||||||
|
|
||||||
DEPDIRS-bdev_error := $(BDEV_DEPS)
|
DEPDIRS-bdev_error := $(BDEV_DEPS)
|
||||||
DEPDIRS-bdev_lvol := $(BDEV_DEPS) lvol blob blob_bdev
|
DEPDIRS-bdev_lvol := $(BDEV_DEPS) lvol blob blob_bdev
|
||||||
|
@ -38,7 +38,6 @@
|
|||||||
|
|
||||||
#include "gpt.h"
|
#include "gpt.h"
|
||||||
|
|
||||||
#include "spdk/conf.h"
|
|
||||||
#include "spdk/endian.h"
|
#include "spdk/endian.h"
|
||||||
#include "spdk/env.h"
|
#include "spdk/env.h"
|
||||||
#include "spdk/thread.h"
|
#include "spdk/thread.h"
|
||||||
@ -90,8 +89,6 @@ struct gpt_io {
|
|||||||
struct spdk_bdev_io_wait_entry bdev_io_wait;
|
struct spdk_bdev_io_wait_entry bdev_io_wait;
|
||||||
};
|
};
|
||||||
|
|
||||||
static bool g_gpt_disabled;
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gpt_base_free(void *ctx)
|
gpt_base_free(void *ctx)
|
||||||
{
|
{
|
||||||
@ -519,13 +516,6 @@ vbdev_gpt_read_gpt(struct spdk_bdev *bdev)
|
|||||||
static int
|
static int
|
||||||
vbdev_gpt_init(void)
|
vbdev_gpt_init(void)
|
||||||
{
|
{
|
||||||
struct spdk_conf_section *sp = spdk_conf_find_section(NULL, "Gpt");
|
|
||||||
|
|
||||||
if (sp && spdk_conf_section_get_boolval(sp, "Disable", false)) {
|
|
||||||
/* Disable Gpt probe */
|
|
||||||
g_gpt_disabled = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -543,7 +533,7 @@ vbdev_gpt_examine(struct spdk_bdev *bdev)
|
|||||||
/* A bdev with fewer than 2 blocks cannot have a GPT. Block 0 has
|
/* A bdev with fewer than 2 blocks cannot have a GPT. Block 0 has
|
||||||
* the MBR and block 1 has the GPT header.
|
* the MBR and block 1 has the GPT header.
|
||||||
*/
|
*/
|
||||||
if (g_gpt_disabled || spdk_bdev_get_num_blocks(bdev) < 2) {
|
if (spdk_bdev_get_num_blocks(bdev) < 2) {
|
||||||
spdk_bdev_module_examine_done(&gpt_if);
|
spdk_bdev_module_examine_done(&gpt_if);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user