^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1) /* SPDX-License-Identifier: GPL-2.0 */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 2) #ifndef _MULTIPATH_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 3) #define _MULTIPATH_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 4)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 5) struct multipath_info {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 6) struct md_rdev *rdev;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 7) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 8)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 9) struct mpconf {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) struct mddev *mddev;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) struct multipath_info *multipaths;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) int raid_disks;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) spinlock_t device_lock;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) struct list_head retry_list;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) mempool_t pool;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) * this is our 'private' 'collective' MULTIPATH buffer head.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) * it contains information about what kind of IO operations were started
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) * for this MULTIPATH operation, and about their status:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) struct multipath_bh {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) struct mddev *mddev;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) struct bio *master_bio;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) struct bio bio;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) int path;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) struct list_head retry_list;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) #endif