<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/infiniband, branch v3.18.62</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v3.18.62</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v3.18.62'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2017-06-14T10:54:21+00:00</updated>
<entry>
<title>mlx5: stop including &lt;asm-generic/kmap_types.h&gt;</title>
<updated>2017-06-14T10:54:21+00:00</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2015-08-28T07:27:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=4489545a1d45d1163f7c6eb83a6c38ee5082d1f5'/>
<id>urn:sha1:4489545a1d45d1163f7c6eb83a6c38ee5082d1f5</id>
<content type='text'>
commit adec640e03668e42f30f3b09c0b4d60d44545f6f upstream.

&lt;linux/highmem.h&gt; is the placace the get the kmap type flags, asm-generic
files are generic implementations only to be used by architecture code.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>RDMA/qib,hfi1: Fix MR reference count leak on write with immediate</title>
<updated>2017-06-14T10:54:20+00:00</updated>
<author>
<name>Mike Marciniszyn</name>
<email>mike.marciniszyn@intel.com</email>
</author>
<published>2017-05-12T16:02:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6dc95d1f9f73e5f5b539ab07443e8510dc700f0b'/>
<id>urn:sha1:6dc95d1f9f73e5f5b539ab07443e8510dc700f0b</id>
<content type='text'>
commit 1feb40067cf04ae48d65f728d62ca255c9449178 upstream.

The handling of IB_RDMA_WRITE_ONLY_WITH_IMMEDIATE will leak a memory
reference when a buffer cannot be allocated for returning the immediate
data.

The issue is that the rkey validation has already occurred and the RNR
nak fails to release the reference that was fruitlessly gotten.  The
the peer will send the identical single packet request when its RNR
timer pops.

The fix is to release the held reference prior to the rnr nak exit.
This is the only sequence the requires both rkey validation and the
buffer allocation on the same packet.

Cc: Stable &lt;stable@vger.kernel.org&gt; # 4.7+
Tested-by: Tadeusz Struk &lt;tadeusz.struk@intel.com&gt;
Reviewed-by: Dennis Dalessandro &lt;dennis.dalessandro@intel.com&gt;
Signed-off-by: Mike Marciniszyn &lt;mike.marciniszyn@intel.com&gt;
Signed-off-by: Dennis Dalessandro &lt;dennis.dalessandro@intel.com&gt;
Signed-off-by: Doug Ledford &lt;dledford@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>IB/mlx4: Fix ib device initialization error flow</title>
<updated>2017-05-20T12:18:41+00:00</updated>
<author>
<name>Jack Morgenstein</name>
<email>jackm@dev.mellanox.co.il</email>
</author>
<published>2017-03-21T10:57:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=28aafa8aa24648fd8a1a67962187b5a7a5e373c4'/>
<id>urn:sha1:28aafa8aa24648fd8a1a67962187b5a7a5e373c4</id>
<content type='text'>
commit 99e68909d5aba1861897fe7afc3306c3c81b6de0 upstream.

In mlx4_ib_add, procedure mlx4_ib_alloc_eqs is called to allocate EQs.

However, in the mlx4_ib_add error flow, procedure mlx4_ib_free_eqs is not
called to free the allocated EQs.

Fixes: e605b743f33d ("IB/mlx4: Increase the number of vectors (EQs) available for ULPs")
Signed-off-by: Jack Morgenstein &lt;jackm@dev.mellanox.co.il&gt;
Signed-off-by: Leon Romanovsky &lt;leon@kernel.org&gt;
Signed-off-by: Doug Ledford &lt;dledford@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>IB/IPoIB: ibX: failed to create mcg debug file</title>
<updated>2017-05-20T12:18:41+00:00</updated>
<author>
<name>Shamir Rabinovitch</name>
<email>shamir.rabinovitch@oracle.com</email>
</author>
<published>2017-03-29T10:21:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f88282f6669777027e45ff1417967914e3965d82'/>
<id>urn:sha1:f88282f6669777027e45ff1417967914e3965d82</id>
<content type='text'>
commit 771a52584096c45e4565e8aabb596eece9d73d61 upstream.

When udev renames the netdev devices, ipoib debugfs entries does not
get renamed. As a result, if subsequent probe of ipoib device reuse the
name then creating a debugfs entry for the new device would fail.

Also, moved ipoib_create_debug_files and ipoib_delete_debug_files as part
of ipoib event handling in order to avoid any race condition between these.

Fixes: 1732b0ef3b3a ([IPoIB] add path record information in debugfs)
Signed-off-by: Vijay Kumar &lt;vijay.ac.kumar@oracle.com&gt;
Signed-off-by: Shamir Rabinovitch &lt;shamir.rabinovitch@oracle.com&gt;
Reviewed-by: Mark Bloch &lt;markb@mellanox.com&gt;
Signed-off-by: Doug Ledford &lt;dledford@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>infiniband: mlx5: avoid a compile-time warning</title>
<updated>2017-05-08T05:44:11+00:00</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2015-01-13T16:09:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=c4a1b5dd7b57c550b8bfd11d4229097eb824532a'/>
<id>urn:sha1:c4a1b5dd7b57c550b8bfd11d4229097eb824532a</id>
<content type='text'>
commit 7835bfb5261501590a508b3de3379e2231cb4853 upstream.

The return type of find_first_bit() is architecture specific,
on ARM it is 'unsigned int', while the asm-generic code used
on x86 and a lot of other architectures returns 'unsigned long'.

When building the mlx5 driver on ARM, we get a warning about
this:

infiniband/hw/mlx5/mem.c: In function 'mlx5_ib_cont_pages':
infiniband/hw/mlx5/mem.c:84:143: warning: comparison of distinct pointer types lacks a cast
     m = min(m, find_first_bit(&amp;tmp, sizeof(tmp)));

This patch changes the driver to use min_t to make it behave
the same way on all architectures.

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Acked-by: Eli Cohen &lt;eli@mellanox.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>IB/ehca: fix maybe-uninitialized warnings</title>
<updated>2017-05-08T05:44:11+00:00</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2017-05-04T20:52:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=704ee89e2992edc23a7ed968d7b806cde044cd9b'/>
<id>urn:sha1:704ee89e2992edc23a7ed968d7b806cde044cd9b</id>
<content type='text'>
The driver causes two warnings about possibly uninitialized variables:

drivers/infiniband/hw/ehca/ehca_mrmw.c: In function 'ehca_set_pagebuf':
drivers/infiniband/hw/ehca/ehca_mrmw.c:1908:4: warning: 'prev_pgaddr' may be used uninitialized in this function [-Wmaybe-uninitialized]
drivers/infiniband/hw/ehca/ehca_mrmw.c:1924:14: note: 'prev_pgaddr' was declared here
drivers/infiniband/hw/ehca/ehca_mrmw.c: In function 'ehca_reg_mr':
drivers/infiniband/hw/ehca/ehca_mrmw.c:2430:5: warning: 'hret' may be used uninitialized in this function [-Wmaybe-uninitialized]

The first one is definitely a false positive, the second one may or may not
be one. In both cases, adding an intialization is the safe and easy
workaround.

The driver was removed in mainline in commit e581d111dad3
("staging/rdma: remove deprecated ehca driver"), in linux-4.6.
In 4.4, the file is located in drivers/staging/rdma/ehca/ehca_mrmw.c,
and the fix still applies.

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>IB/qib: rename BITS_PER_PAGE to RVT_BITS_PER_PAGE</title>
<updated>2017-05-08T05:44:11+00:00</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2017-05-04T20:52:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=a4ba3cd5247dba522544dee5153e9148b621b5f8'/>
<id>urn:sha1:a4ba3cd5247dba522544dee5153e9148b621b5f8</id>
<content type='text'>
We get this build warning on arm64

drivers/infiniband/hw/qib/qib_qp.c:44:0: error: "BITS_PER_PAGE" redefined [-Werror]
 #define BITS_PER_PAGE           (PAGE_SIZE*BITS_PER_BYTE)

This is fixed upstream in commit 898fa52b4ac3 ("IB/qib: Remove qpn, qp tables and
related variables from qib"), which does a lot of other things as well.

Instead, I just backport the rename of the local BITS_PER_PAGE definition to
RVT_BITS_PER_PAGE.

The driver first showed up in linux-2.6.35, and the fixup should still apply
to that. The upstream fix went into v4.6, so we could apply this workaround
to both 3.18 and 4.4.

Fixes: f931551bafe1 ("IB/qib: Add new qib driver for QLogic PCIe InfiniBand adapters")
Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>IB/iser: Fix sparse warnings</title>
<updated>2017-05-08T05:44:09+00:00</updated>
<author>
<name>Sagi Grimberg</name>
<email>sagig@mellanox.com</email>
</author>
<published>2014-12-07T14:09:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=1b4b9dc59074b1bbd32aca0426e6c259304b6b0c'/>
<id>urn:sha1:1b4b9dc59074b1bbd32aca0426e6c259304b6b0c</id>
<content type='text'>
commit 49df2781b101a729e9f46eddc845a587fc5665a8 upstream.

Use uintptr_t to handle wr_id casting, which was found by Kbuild test
robot and smatch.  Also remove an internal definition of variable which
potentially shadows an external one (and make sparse happy).

Signed-off-by: Sagi Grimberg &lt;sagig@mellanox.com&gt;
Signed-off-by: Or Gerlitz &lt;ogerlitz@mellanox.com&gt;
Signed-off-by: Roland Dreier &lt;roland@purestorage.com&gt;
Cc: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>IB/ipoib: Fix deadlock between rmmod and set_mode</title>
<updated>2017-04-18T05:55:49+00:00</updated>
<author>
<name>Feras Daoud</name>
<email>ferasda@mellanox.com</email>
</author>
<published>2016-12-28T12:47:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=4161529ef017c8f5f577845a17a2bc64cba93402'/>
<id>urn:sha1:4161529ef017c8f5f577845a17a2bc64cba93402</id>
<content type='text'>
commit 0a0007f28304cb9fc87809c86abb80ec71317f20 upstream.

When calling set_mode from sys/fs, the call flow locks the sys/fs lock
first and then tries to lock rtnl_lock (when calling ipoib_set_mod).
On the other hand, the rmmod call flow takes the rtnl_lock first
(when calling unregister_netdev) and then tries to take the sys/fs
lock. Deadlock a-&gt;b, b-&gt;a.

The problem starts when ipoib_set_mod frees it's rtnl_lck and tries
to get it after that.

    set_mod:
    [&lt;ffffffff8104f2bd&gt;] ? check_preempt_curr+0x6d/0x90
    [&lt;ffffffff814fee8e&gt;] __mutex_lock_slowpath+0x13e/0x180
    [&lt;ffffffff81448655&gt;] ? __rtnl_unlock+0x15/0x20
    [&lt;ffffffff814fed2b&gt;] mutex_lock+0x2b/0x50
    [&lt;ffffffff81448675&gt;] rtnl_lock+0x15/0x20
    [&lt;ffffffffa02ad807&gt;] ipoib_set_mode+0x97/0x160 [ib_ipoib]
    [&lt;ffffffffa02b5f5b&gt;] set_mode+0x3b/0x80 [ib_ipoib]
    [&lt;ffffffff8134b840&gt;] dev_attr_store+0x20/0x30
    [&lt;ffffffff811f0fe5&gt;] sysfs_write_file+0xe5/0x170
    [&lt;ffffffff8117b068&gt;] vfs_write+0xb8/0x1a0
    [&lt;ffffffff8117ba81&gt;] sys_write+0x51/0x90
    [&lt;ffffffff8100b0f2&gt;] system_call_fastpath+0x16/0x1b

    rmmod:
    [&lt;ffffffff81279ffc&gt;] ? put_dec+0x10c/0x110
    [&lt;ffffffff8127a2ee&gt;] ? number+0x2ee/0x320
    [&lt;ffffffff814fe6a5&gt;] schedule_timeout+0x215/0x2e0
    [&lt;ffffffff8127cc04&gt;] ? vsnprintf+0x484/0x5f0
    [&lt;ffffffff8127b550&gt;] ? string+0x40/0x100
    [&lt;ffffffff814fe323&gt;] wait_for_common+0x123/0x180
    [&lt;ffffffff81060250&gt;] ? default_wake_function+0x0/0x20
    [&lt;ffffffff8119661e&gt;] ? ifind_fast+0x5e/0xb0
    [&lt;ffffffff814fe43d&gt;] wait_for_completion+0x1d/0x20
    [&lt;ffffffff811f2e68&gt;] sysfs_addrm_finish+0x228/0x270
    [&lt;ffffffff811f2fb3&gt;] sysfs_remove_dir+0xa3/0xf0
    [&lt;ffffffff81273f66&gt;] kobject_del+0x16/0x40
    [&lt;ffffffff8134cd14&gt;] device_del+0x184/0x1e0
    [&lt;ffffffff8144e59b&gt;] netdev_unregister_kobject+0xab/0xc0
    [&lt;ffffffff8143c05e&gt;] rollback_registered+0xae/0x130
    [&lt;ffffffff8143c102&gt;] unregister_netdevice+0x22/0x70
    [&lt;ffffffff8143c16e&gt;] unregister_netdev+0x1e/0x30
    [&lt;ffffffffa02a91b0&gt;] ipoib_remove_one+0xe0/0x120 [ib_ipoib]
    [&lt;ffffffffa01ed95f&gt;] ib_unregister_device+0x4f/0x100 [ib_core]
    [&lt;ffffffffa021f5e1&gt;] mlx4_ib_remove+0x41/0x180 [mlx4_ib]
    [&lt;ffffffffa01ab771&gt;] mlx4_remove_device+0x71/0x90 [mlx4_core]

Fixes: 862096a8bbf8 ("IB/ipoib: Add more rtnl_link_ops callbacks")
Cc: Or Gerlitz &lt;ogerlitz@mellanox.com&gt;
Signed-off-by: Feras Daoud &lt;ferasda@mellanox.com&gt;
Signed-off-by: Erez Shitrit &lt;erezsh@mellanox.com&gt;
Signed-off-by: Leon Romanovsky &lt;leon@kernel.org&gt;
Signed-off-by: Doug Ledford &lt;dledford@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>IPoIB: Avoid reading an uninitialized member variable</title>
<updated>2017-01-15T14:49:52+00:00</updated>
<author>
<name>Bart Van Assche</name>
<email>bart.vanassche@sandisk.com</email>
</author>
<published>2016-11-21T18:21:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=8dcd21b372737c2e75d9f60807573067d01c895f'/>
<id>urn:sha1:8dcd21b372737c2e75d9f60807573067d01c895f</id>
<content type='text'>
[ Upstream commit 11b642b84e8c43e8597de031678d15c08dd057bc ]

This patch avoids that Coverity reports the following:

    Using uninitialized value port_attr.state when calling printk

Fixes: commit 94232d9ce817 ("IPoIB: Start multicast join process only on active ports")
Signed-off-by: Bart Van Assche &lt;bart.vanassche@sandisk.com&gt;
Cc: Erez Shitrit &lt;erezsh@mellanox.com&gt;
Cc: &lt;stable@vger.kernel.org&gt;
Reviewed-by: Leon Romanovsky &lt;leonro@mellanox.com&gt;
Signed-off-by: Doug Ledford &lt;dledford@redhat.com&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@verizon.com&gt;
</content>
</entry>
</feed>
