>From dbee2d4f4777c6884b9d1158da051370f18354f3 Mon Sep 17 00:00:00 2001 From: Prasad Joshi <[email protected]> Date: Mon, 24 Sep 2012 22:20:14 +0530 Subject: [PATCH] get_disk_list must return list of devices on machine
get_disk_list with non default arguments, std_mounts_only=False and get_all_disks=True, must return all of the disks discoverable on the system. The code was incorrectly testing for device_name, resulting in skipping the devices without partition. Since the device_name is no longer needed, it can be removed. Signed-off-by: Prasad Joshi <[email protected]> --- client/fsdev_disks.py | 9 --------- 1 files changed, 0 insertions(+), 9 deletions(-) diff --git a/client/fsdev_disks.py b/client/fsdev_disks.py index 9386752..9db6365 100644 --- a/client/fsdev_disks.py +++ b/client/fsdev_disks.py @@ -119,8 +119,6 @@ def get_disk_list(std_mounts_only=True, get_all_disks=False): if std_mounts_only and mstat < 0: continue - device_name = '' - if not get_all_disks: # Was this partition mounted at all? if not mountpt: @@ -128,13 +126,6 @@ def get_disk_list(std_mounts_only=True, get_all_disks=False): # Ask the client where we should mount this partition if not mountpt: continue - else: - if partname[-1:].isdigit(): - device_name = re.sub("\d", "", "/dev/%s" % partname) - - if get_all_disks: - if not device_name: - continue # Looks like we have a valid disk drive, add it to the list hd_list.append({ 'device' : partname, -- 1.7.5.4
0001-get_disk_list-must-return-list-of-devices-on-machine.patch
Description: Binary data
_______________________________________________ Autotest-kernel mailing list [email protected] https://www.redhat.com/mailman/listinfo/autotest-kernel
