Commit Graph

6 Commits

Author SHA1 Message Date
Mike Fleetwood 66bb88abf7 Recognise NVME devices (#755022)
Add a pattern to recognise Non-Volatile Memory Express devices as valid
devices to work with.  Devices are named by the Linux kernel device
driver like /dev/nvme0n1 [1] with partitions named like /dev/nvme0n1p1
[2].

[1] linux 3.3 drivers/block/nvme.c nvme_alloc_ns()
    https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/drivers/block/nvme.c?id=v3.3#n1351

[2] Contents of /proc/partitions for a partitioned NVME device
    $ grep nvme /proc/partitions
     259        0  390711384 nvme0n1
     259        1        977 nvme0n1p1
     259        2   31250000 nvme0n1p2
     259        3  328209496 nvme0n1p3
     259        4   31249408 nvme0n1p4

Bug 755022 - gparted doesn't recognize nvme devices
2015-09-21 09:47:31 -06:00
Daniel Mustieles 3861b9257b Replace obsolete FSF postal address in copyright notices (#721565)
This is part of parent bug:
    Bug #721455 - Obsolete info in license text on multiple modules

and GNOME Goal:
    https://wiki.gnome.org/Initiatives/GnomeGoals/Proposals

    * verify all source files to make sure they have a license and a
      copyright, and that both are up-to-date

Bug #721565 -  License text contains obsolete FSF postal address
2014-01-26 10:53:23 +00:00
Curtis Gedak c600095912 Add regexp for Linux SW RAID devices in /proc/partitions (#678379)
Add regular expression to detect the device entry only (e.g., md127)
and not the partitions (e.g., md127p1).

Linux software RAID devices are listed in /proc/partitions as follows:

# cat /proc/partitions
major minor  #blocks  name
   9   127     523968 md127
 259     0     131072 md127p1
 259     1     262144 md127p2

Part of Bug #678379 - Could not stat device /dev/md/0 - No such file
                      or directory
2012-12-05 09:51:50 -07:00
Curtis Gedak f003b3c4f2 Tighten up regexp for HP Smart Array Devices
HP Smart Array Devices are listed in /proc/partitions as follows:

major minor  #blocks  name
 104     0  143338560 cciss/c0d0
 104     1     104391 cciss/c0d0p1
 104     2      24097 cciss/c0d0p2
 104     3  143203410 cciss/c0d0p3

The previous regular expression was too broad, and would match many
other forms, including Linux software RAID devices such as md127.

Linux software RAID devices are listed in /proc/partitions as follows:

major minor  #blocks  name
   9   127     523968 md127
 259     0     131072 md127p1
 259     1     262144 md127p2

This problem with the regexp was discovered while investigating a
problem with Linux software RAID device detection.

The regular expression has been tightened up to match the following
hardware RAID controllers:

  Compaq/HP Smartarray RAID controller
    E.g., device = /dev/cciss/c0d0, partition = /dev/cciss/c0d0p1
    (linux-x.y.z/Documentation/blockdev/cciss.txt)

  Compaq SMART2 Intelligent Disk Array controller
    E.g., device = /dev/ida/c0d0, partition = /dev/ida/c0d0p1
    (linux-x.y.z/Documentation/blockdev/cpqarray.txt)

  Mylex DAC960/AcceleRAID/eXtremeRAID PCI RAID Controllers
    E.g., device = /dev/rd/c0d0,  partition = /dev/rd/c0d0p1
    (linux-x.y.z/Documentation/blockdev/README.DAC960)

Related to Bug #678379 - Could not stat device /dev/md/0 - No such
                         file or directory
2012-12-05 09:51:50 -07:00
Curtis Gedak fd77e73c46 Refactor device parsing logic into Proc_Partitions_Info class
The reason for refactoring is to simplify the large GParted_Core
class, to help minimize disk reads, and to group the logic for
processing the file /proc/partitions into a single logical class.
2010-12-07 16:01:54 -07:00
Curtis Gedak 319255d3bc Refactor alternate_paths logic into new Proc_Partitions_Info class
This reason for refactoring is to simplify the large GParted_Core
class, to help minimize disk reads, and to group the logic for
processing the file /proc/partitions into a single logical class.
2010-12-07 11:49:50 -07:00