<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/message/fusion, branch v6.1.168</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.1.168</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.1.168'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2024-12-14T18:53:40+00:00</updated>
<entry>
<title>scsi: fusion: Remove unused variable 'rc'</title>
<updated>2024-12-14T18:53:40+00:00</updated>
<author>
<name>Zeng Heng</name>
<email>zengheng4@huawei.com</email>
</author>
<published>2024-10-24T08:44:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=31f29289c7eace62a29007bf00e09a6d8339ad7e'/>
<id>urn:sha1:31f29289c7eace62a29007bf00e09a6d8339ad7e</id>
<content type='text'>
[ Upstream commit bd65694223f7ad11c790ab63ad1af87a771192ee ]

The return value of scsi_device_reprobe() is currently ignored in
_scsih_reprobe_lun(). Fixing the calling code to deal with the potential
error is non-trivial, so for now just WARN_ON().

The handling of scsi_device_reprobe()'s return value refers to
_scsih_reprobe_lun() and the following link:

https://lore.kernel.org/all/094fdbf57487af4f395238c0525b2a560c8f68f0.1469766027.git.calvinowens@fb.com/

Fixes: f99be43b3024 ("[SCSI] fusion: power pc and miscellaneous bug fixs")
Signed-off-by: Zeng Heng &lt;zengheng4@huawei.com&gt;
Link: https://lore.kernel.org/r/20241024084417.154655-1-zengheng4@huawei.com
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>scsi: message: mptlan: Fix use after free bug in mptlan_remove() due to race condition</title>
<updated>2023-05-24T16:32:37+00:00</updated>
<author>
<name>Zheng Wang</name>
<email>zyytlz.wz@163.com</email>
</author>
<published>2023-03-18T08:16:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=9c6da3b7f12528cd52c458b33496a098b838fcfc'/>
<id>urn:sha1:9c6da3b7f12528cd52c458b33496a098b838fcfc</id>
<content type='text'>
[ Upstream commit f486893288f3e9b171b836f43853a6426515d800 ]

mptlan_probe() calls mpt_register_lan_device() which initializes the
&amp;priv-&gt;post_buckets_task workqueue. A call to
mpt_lan_wake_post_buckets_task() will subsequently start the work.

During driver unload in mptlan_remove() the following race may occur:

CPU0                  CPU1

                    |mpt_lan_post_receive_buckets_work()
mptlan_remove()     |
  free_netdev()     |
    kfree(dev);     |
                    |
                    | dev-&gt;mtu
                    |   //use

Fix this by finishing the work prior to cleaning up in mptlan_remove().

[mkp: we really should remove mptlan instead of attempting to fix it]

Signed-off-by: Zheng Wang &lt;zyytlz.wz@163.com&gt;
Link: https://lore.kernel.org/r/20230318081635.796479-1-zyytlz.wz@163.com
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>scsi: message: fusion: Remove redundant variable iocnum</title>
<updated>2022-09-01T03:39:57+00:00</updated>
<author>
<name>Colin Ian King</name>
<email>colin.i.king@gmail.com</email>
</author>
<published>2022-08-05T11:32:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=231159f33436326c97fd5f05a1926cae3e5b7885'/>
<id>urn:sha1:231159f33436326c97fd5f05a1926cae3e5b7885</id>
<content type='text'>
Variable iocnum is assigned a value that is never read, the assignment and
hence the variable are redundant can be removed. Also update the comment to
reflect the correct name of the variable being updated.

Cleans up clang-scan warning:

drivers/message/fusion/mptctl.c:641:8: warning: Although the value stored
to 'iocnum' is used in the enclosing expression, the value is never
actually read from 'iocnum' [deadcode.DeadStores]

Link: https://lore.kernel.org/r/20220805113214.2339022-1-colin.i.king@gmail.com
Signed-off-by: Colin Ian King &lt;colin.i.king@gmail.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: message: fusion: Drop redundant "the"</title>
<updated>2022-06-22T01:34:52+00:00</updated>
<author>
<name>Jiang Jian</name>
<email>jiangjian@cdjrlc.com</email>
</author>
<published>2022-06-21T10:31:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=950d2867c1fb87a90e2f42c35d548e22733d4e0e'/>
<id>urn:sha1:950d2867c1fb87a90e2f42c35d548e22733d4e0e</id>
<content type='text'>
Redundant "the" in the comments can be dropped.

Link: https://lore.kernel.org/r/20220621103119.91492-1-jiangjian@cdjrlc.com
Signed-off-by: Jiang Jian &lt;jiangjian@cdjrlc.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: message: fusion: Remove unused variable retval</title>
<updated>2022-04-26T03:26:32+00:00</updated>
<author>
<name>Alexander Vorwerk</name>
<email>alexander.vorwerk@stud.uni-goettingen.de</email>
</author>
<published>2022-03-17T03:03:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ce781c3f05cd93515e31091def848c134f5bb2f2'/>
<id>urn:sha1:ce781c3f05cd93515e31091def848c134f5bb2f2</id>
<content type='text'>
The following warning showed up when compiling with W=1.

drivers/message/fusion/mptctl.c: In function ‘mptctl_hp_hostinfo’:
drivers/message/fusion/mptctl.c:2337:8: warning: variable ‘retval’ set but not used [-Wunused-but-set-variable]
  int   retval;

Fixing by removing the variable.

Link: https://lore.kernel.org/r/20220317030325.30526-1-alexander.vorwerk@stud.uni-goettingen.de
Signed-off-by: Alexander Vorwerk &lt;alexander.vorwerk@stud.uni-goettingen.de&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: message: fusion: Remove redundant variable dmp</title>
<updated>2022-04-07T02:28:07+00:00</updated>
<author>
<name>Colin Ian King</name>
<email>colin.i.king@gmail.com</email>
</author>
<published>2022-03-18T00:39:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=61144d83376a136d8aa7a9e057d916c505bfb75f'/>
<id>urn:sha1:61144d83376a136d8aa7a9e057d916c505bfb75f</id>
<content type='text'>
Variable dmp is being assigned a value that is never read, the variable is
redundant and can be removed.

Cleans up clang scan build warning:
drivers/message/fusion/mptbase.c:6667:39: warning: Although
the value stored to 'dmp' is used in the enclosing expression,
the value is never actually read from 'dmp' [deadcode.DeadStores]

Link: https://lore.kernel.org/r/20220318003927.81471-1-colin.i.king@gmail.com
Reviewed-by: Nick Desaulniers &lt;ndesaulniers@google.com&gt;
Signed-off-by: Colin Ian King &lt;colin.i.king@gmail.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: message: fusion: Use GFP_KERNEL instead of GFP_ATOMIC in non-atomic context</title>
<updated>2022-02-28T02:21:21+00:00</updated>
<author>
<name>Christophe JAILLET</name>
<email>christophe.jaillet@wanadoo.fr</email>
</author>
<published>2022-02-15T06:32:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=e3af2e3b0019d9040f7cce39a8992cb4c03a087b'/>
<id>urn:sha1:e3af2e3b0019d9040f7cce39a8992cb4c03a087b</id>
<content type='text'>
Just a few lines below this kzalloc() we have a mutex_lock() which can
sleep.

Moreover, the only way to call this function is when a delayed work is
schedule. And delayed work can sleep:

  INIT_DELAYED_WORK(&amp;fw_event-&gt;work, mptsas_firmware_event_work);
    --&gt; mptsas_firmware_event_work()
      --&gt; mptsas_send_link_status_event()
        --&gt; mptsas_expander_add()

So there is really no good reason to use GFP_ATOMIC here. Change it to
GFP_KERNEL to give more opportunities to the kernel.

Link: https://lore.kernel.org/r/eccb2179ce800529851ed4fabc9d3f95fbbf7d7f.1644906731.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: message: fusion: Use GFP_KERNEL</title>
<updated>2022-02-11T22:09:27+00:00</updated>
<author>
<name>Julia Lawall</name>
<email>Julia.Lawall@inria.fr</email>
</author>
<published>2022-02-10T20:42:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f69b0791df1d1db931ee42a20de41446a955f84e'/>
<id>urn:sha1:f69b0791df1d1db931ee42a20de41446a955f84e</id>
<content type='text'>
Pci_driver probe functions aren't called with locks held and thus don't
need GFP_ATOMIC. Use GFP_KERNEL instead.

Problem found with Coccinelle.

Link: https://lore.kernel.org/r/20220210204223.104181-9-Julia.Lawall@inria.fr
Signed-off-by: Julia Lawall &lt;Julia.Lawall@inria.fr&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: message: fusion: mptctl: Use dma_alloc_coherent()</title>
<updated>2022-01-10T15:33:52+00:00</updated>
<author>
<name>Christophe JAILLET</name>
<email>christophe.jaillet@wanadoo.fr</email>
</author>
<published>2022-01-06T21:54:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=706dc3b91989a1286b0eb75a1cd816596c590e5c'/>
<id>urn:sha1:706dc3b91989a1286b0eb75a1cd816596c590e5c</id>
<content type='text'>
In [1], Christoph Hellwig has proposed to remove the wrappers in
include/linux/pci-dma-compat.h.

Some reasons why this API should be removed have been given by Julia
Lawall in [2].

When memory is allocated in kbuf_alloc_2_sgl() GFP_KERNEL can be used
because this function already uses the GFP_USER flag for some memory
allocation and not spin_lock is taken in the between.

When memory is allocated in mptctl_do_mpt_command() GFP_KERNEL can be used
because this function already uses copy_from_user() and this function can
sleep.

When memory is allocated in mptctl_hp_hostinfo() GFP_KERNEL can be used
because this function already uses mpt_config() and this function has an
explicit might_sleep().

When memory is allocated in mptctl_hp_targetinfo() GFP_KERNEL can be used
because this function already uses mpt_config() and this function has an
explicit might_sleep().

[1]: https://lore.kernel.org/kernel-janitors/20200421081257.GA131897@infradead.org/
[2]: https://lore.kernel.org/kernel-janitors/alpine.DEB.2.22.394.2007120902170.2424@hadrien/

Link: https://lore.kernel.org/r/516375d6d06114484533baf03aae351306100246.1641500561.git.christophe.jaillet@wanadoo.fr
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
<entry>
<title>scsi: message: fusion: mptsas: Use dma_alloc_coherent()</title>
<updated>2022-01-10T15:33:52+00:00</updated>
<author>
<name>Christophe JAILLET</name>
<email>christophe.jaillet@wanadoo.fr</email>
</author>
<published>2022-01-06T21:54:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=76a334d756c596f2f283e1d0054477ba0f0eacf6'/>
<id>urn:sha1:76a334d756c596f2f283e1d0054477ba0f0eacf6</id>
<content type='text'>
In [1], Christoph Hellwig has proposed to remove the wrappers in
include/linux/pci-dma-compat.h.

Some reasons why this API should be removed have been given by Julia
Lawall in [2].

In all these places where some memory is allocated GFP_KERNEL can be used
because they already call mpt_config() which has an explicit might_sleep().

[1]: https://lore.kernel.org/kernel-janitors/20200421081257.GA131897@infradead.org/
[2]: https://lore.kernel.org/kernel-janitors/alpine.DEB.2.22.394.2007120902170.2424@hadrien/

Link: https://lore.kernel.org/r/443b81ecb08b2fe6f789bb2fdff13a53c809e401.1641500561.git.christophe.jaillet@wanadoo.fr
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
</entry>
</feed>
