udev: typo in rdma_ucm rules

Bug #192552 reported by Roland Dreier
8
Affects Status Importance Assigned to Milestone
udev (Ubuntu)
Fix Released
Medium
Scott James Remnant (Canonical)

Bug Description

Unfortunately the rules that I included in the report for bug #124990 that added handling
of the rdma_ucm module's misc device had a typo. Although the module name is
rdma_ucm, the device that is created has

   KERNEL=="rdma_cm"

as its name, so the udev rules need to use rdma_cm instead of rdma_ucm.

To be precise, in /etc/udev/rules.d/20-names.rules, the line

   KERNEL=="rdma_ucm", NAME="infiniband/%k"

should really be:

   KERNEL=="rdma_cm", NAME="infiniband/%k"

You can test this by doing "modprobe rdma_ucm" and looking at where the "rdma_cm"
node shows up (you don't need any RDMA hardware to do this--it will work on any
system). With the current rules, you will get /dev/rdma_cm instead of the intended
/dev/infiniband/rdma_cm, and so libraries that look in the standard place will not work.

Revision history for this message
Bart Van Assche (bart-vanassche) wrote :

At least in Ubuntu 7.10 server, there are more typo's in the Ubuntu udev rules than what is mentioned above. The following patch fixed the InfiniBand-related udev issues for me:

--- orig/20-names.rules 2008-02-21 08:59:12.000000000 +0100
+++ 20-names.rules 2008-02-21 09:01:49.000000000 +0100
@@ -19,10 +19,10 @@

 # Infiniband devices
 KERNEL=="umad[0-9]*", NAME="infiniband/%k"
-KERNEL=="issm[0-9]*, NAME="infiniband/%k"
-KERNEL=="uverbs[0-9]*, NAME="infiniband/%k"
-KERNEL=="ucm[0-9]*, NAME="infiniband/%k"
-KERNEL=="rdma_ucm", NAME="infiniband/%k"
+KERNEL=="issm[0-9]*", NAME="infiniband/%k"
+KERNEL=="uverbs[0-9]*", NAME="infiniband/%k"
+KERNEL=="ucm[0-9]*", NAME="infiniband/%k"
+KERNEL=="rdma_cm", NAME="infiniband/%k"

 # Input devices, group under /dev/input
 KERNEL=="event[0-9]*", NAME="input/%k"

Revision history for this message
Bart Van Assche (bart-vanassche) wrote :

Attached the inline quoted patch.

Revision history for this message
Roland Dreier (roland.dreier) wrote :

Yes, good point... the issm, uverbs and ucm rules are all missing closing quotes (") for the KERNEL== part of the rules.

Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote :

I already have a fix for this pending upload with other changes.

Changed in udev:
assignee: nobody → keybuk
status: New → In Progress
Changed in udev:
importance: Undecided → Medium
status: In Progress → Fix Committed
Revision history for this message
ake sandgren (ake-sandgren) wrote :

The missing " are still missing in hardy.
Please fix before final release.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package udev - 117-5

---------------
udev (117-5) hardy; urgency=low

  * Merge the "volumeid" package back into "udev", there is no particular
    gain to it being a separate binary package and it prevents the upgrade
    from dapper from migrating the fstab to UUID. LP: #209347.

  * debian/patches/00-git-bad-net-rules.patch:
    - Upstream patch from 118 to avoid creating persistent net rules
      which will match any device.
  * debian/patches/01-git-squashfs-lzma.patch:
    - Upstream patch from 118 to detect LZMA-compressed squashfs.
  * debian/patches/02-git-squashfs-endian.patch:
    - Upstream patch from 118 to detect endianness of LZMA squashfs.
  * debian/patches/03-git-vol_id-timeout-once.patch:
    - Upstream patch from 118 to only timeout once for unreadable devices.
      LP: #156184.
  * debian/patches/04-git-multiple-floppy-devices.patch:
    - Upstream patch from 118 to fix create_floppy_devices for more than
      one floppy device. Possibly LP: #132546.
  * debian/patches/05-git-vol_id-probe_all-readable.patch:
    - Upstream patch from 118 to check whether a device is readable before
      probing. Also LP: #156184.
  * debian/patches/00upstream-RUN-for-remove.patch:
    - Rename to 06-git-run-for-remove.patch so its in series with other
      git patches (this is from 119)
  * debian/patches/07-git-unlock-write_net_rules.patch:
    - Upstream patch from 119 to unlock rules after invalid match, correcting
      a bug introduced by 00-git-bad-net-rules.patch
  * debian/patches/08-git-vol_id-uuid-buffer.patch:
    - Upstream patch from 119 to correct UUID raw buffer usage.
  * debian/patches/09-git-update-ext.patch:
    - Upstream patch from 119 to update ext filesystem detection.
  * debian/patches/10-git-match-basename.patch:
    - Upstream patch from 119 to add match on the basename of an interface
      so we can deal with PS3 multiple interfaces with the same MAC.
  * debian/patches/11-git-persistent-change.patch:
    - Upstream patch from 119 to run persistent device rules on change
      events.
  * debian/patches/12-git-serialise-same-devno.patch:
    - Upstream patch from git to serialise multiple events with the same
      device number, fixes a race with serial ttys amongst other things.

  * 20-names.rules:
    - Add missing quotes for infiniband rules. LP: #192552.
    - Change "rdma_ucm" to "rdma_cm" (same bug).
  * 40-permissions.rules, 40-basic-permissions.rules:
    - Split out the most basic permissions into a separate file that can be
      used in the installer and initramfs. LP: #204108.
    - Add rules to place known USB serial devices that need libusb access
      in the dialout group. LP: #198757.
  * 65-persistent-storage.rules, 65-persistent-storage-tape.rules,
    65-persistent-input.rules, 66-persistent-storage-edd.rules:
    - Use upstream rule names for all rules. Also LP: #186686.
    - Add persistent-storage-edd.rules to installer and initramfs.
  * 80-programs.rules:
    - Pass $root/%k to create-floppy-devices, not $tempnode. LP: #132546.

 -- Scott James Remnant <email address hidden> Wed, 02 Apr 2008 18:59:56 +0100

Changed in udev:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.