opensvc / multipath-tools

Other
60 stars 48 forks source link

multipath.conf.5: fix the description of prio_args for path_latency prio #87

Closed Cav4ever closed 3 months ago

Cav4ever commented 5 months ago

This aligns the description of prio_args for path_latency prio and the actual code.

I've already sent this patch to the mailing list for multipath-tools(dm-devel@lists.linux.dev). https://lore.kernel.org/dm-devel/tencent_28B810D5C1E1C6C30580729B90CA3CBFAF0A@qq.com/

Cav4ever commented 5 months ago

In the code, io_num is of type int in the range [20, 200] and base_num is of type double in the range [1.1, 10].

// libmultipath/prioritizers/path_latency.c
#define MAX_IO_NUM      200
#define MIN_IO_NUM      20
#define DEF_IO_NUM      100

#define MAX_BASE_NUM        10
#define MIN_BASE_NUM        1.1

// libmultipath/prioritizers/path_latency.c
int check_args_valid(int io_num, double base_num)

The multipath.conf man page states that io_num is in the range [2,200] and base_num is an int in the range [2,10]. Referring to the man page to configure io_num to 10 and base_num to 10, io_num is indeed out of the range of [20, 200].

mwilck commented 5 months ago

LGTM, thanks.

I also ack'd this on dm-devel (assuming you are the same person that created this post).

I'd rather postpone it until #85 is merged, though.

Cav4ever commented 5 months ago

I also ack'd this on dm-devel (assuming you are the same person that created this post).

Yes, it's me. Thanks.