<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/sys/dev/mpr/mpr.c, branch release/12.4.0</title>
<subtitle>FreeBSD source tree</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/'/>
<entry>
<title>Fix mpr(4) panic during a firmware update.</title>
<updated>2022-10-20T14:57:55+00:00</updated>
<author>
<name>Kenneth D. Merry</name>
<email>ken@FreeBSD.org</email>
</author>
<published>2022-10-17T16:48:34+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=956f15e74d66c7f9cfd35a8ac553c48fb5624b56'/>
<id>956f15e74d66c7f9cfd35a8ac553c48fb5624b56</id>
<content type='text'>
Issue Description:
The RequestCredits field of IOCFacts got changed between the Phase23
firmware to Phase24 firmware. So as part of firmware update operation,
driver has to free the resources &amp; pools which are created with the Phase23
Firmware's IOCFacts data (i.e. during driver load time) and has to
reallocate the resources and pools using Phase24's IOCFacts data. Here
driver has freed the interrupts but missed to reallocate the interrupts and
hence config page read operation is getting timed out and controller is
going for recursive reinit (controller reset) operations and leading to
kernel panic.

Fix:
Reallocate the interrupts if the interrupts are disabled as part of
firmware update/downgrade operation.

Submitted by:	Sreekanth Ready &lt;sreekanth.reddy@broadcom.com&gt;
Tested by:	ken
MFC after:	3 days

(cherry picked from commit 11778fca4a83f5e3b597c75785aa5c0ee0dc518e)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Issue Description:
The RequestCredits field of IOCFacts got changed between the Phase23
firmware to Phase24 firmware. So as part of firmware update operation,
driver has to free the resources &amp; pools which are created with the Phase23
Firmware's IOCFacts data (i.e. during driver load time) and has to
reallocate the resources and pools using Phase24's IOCFacts data. Here
driver has freed the interrupts but missed to reallocate the interrupts and
hence config page read operation is getting timed out and controller is
going for recursive reinit (controller reset) operations and leading to
kernel panic.

Fix:
Reallocate the interrupts if the interrupts are disabled as part of
firmware update/downgrade operation.

Submitted by:	Sreekanth Ready &lt;sreekanth.reddy@broadcom.com&gt;
Tested by:	ken
MFC after:	3 days

(cherry picked from commit 11778fca4a83f5e3b597c75785aa5c0ee0dc518e)
</pre>
</div>
</content>
</entry>
<entry>
<title>mpr(4): Fix a typo in a source code comment</title>
<updated>2021-12-03T15:56:57+00:00</updated>
<author>
<name>Gordon Bergling</name>
<email>gbe@FreeBSD.org</email>
</author>
<published>2021-11-30T09:40:50+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=3e3f9791eac960e64935f75f722b16bbf43dac0a'/>
<id>3e3f9791eac960e64935f75f722b16bbf43dac0a</id>
<content type='text'>
- s/segement/segment/

(cherry picked from commit ddeb702f7b29d967f86ae705b5604c4fa81bb908)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- s/segement/segment/

(cherry picked from commit ddeb702f7b29d967f86ae705b5604c4fa81bb908)
</pre>
</div>
</content>
</entry>
<entry>
<title>mpr: big-endian support</title>
<updated>2021-12-01T18:42:58+00:00</updated>
<author>
<name>Alfredo Dal'Ava Junior</name>
<email>alfredo@FreeBSD.org</email>
</author>
<published>2021-03-02T14:05:15+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=6cc44223cb6717795afdac4348bbe7e2a968a07d'/>
<id>6cc44223cb6717795afdac4348bbe7e2a968a07d</id>
<content type='text'>
This fixes mpr driver on big-endian devices.
Tested on powerpc64 and powerpc64le targets using a SAS9300-8i card
(LSISAS3008 pci vendor=0x1000 device=0x0097)

Submitted by:	Andre Fernando da Silva &lt;andre.silva@eldorado.org.br&gt;
Reviewed by:	luporl, alfredo, Sreekanth Reddy &lt;sreekanth.reddy@broadcom.com&gt; (by email)
Sponsored by:	Eldorado Research Institute (eldorado.org.br)
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D25785

(cherry picked from commit 71900a794da046ad5322caae2774aed5b3d361b9)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This fixes mpr driver on big-endian devices.
Tested on powerpc64 and powerpc64le targets using a SAS9300-8i card
(LSISAS3008 pci vendor=0x1000 device=0x0097)

Submitted by:	Andre Fernando da Silva &lt;andre.silva@eldorado.org.br&gt;
Reviewed by:	luporl, alfredo, Sreekanth Reddy &lt;sreekanth.reddy@broadcom.com&gt; (by email)
Sponsored by:	Eldorado Research Institute (eldorado.org.br)
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D25785

(cherry picked from commit 71900a794da046ad5322caae2774aed5b3d361b9)
</pre>
</div>
</content>
</entry>
<entry>
<title>MFC r363608:</title>
<updated>2020-08-03T23:06:33+00:00</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2020-08-03T23:06:33+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=9c4a78a41a2cdce7b1a749ad9a295a8953faa9ab'/>
<id>9c4a78a41a2cdce7b1a749ad9a295a8953faa9ab</id>
<content type='text'>
mpr(4), mps(4): Stop checking for failures from malloc(M_WAITOK).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
mpr(4), mps(4): Stop checking for failures from malloc(M_WAITOK).
</pre>
</div>
</content>
</entry>
<entry>
<title>Catch up with stability fixes to mpr/mps in -current since 12</title>
<updated>2019-09-26T01:54:24+00:00</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2019-09-26T01:54:24+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=40d21e921a551c61306276dfee10a5529ffe6dbf'/>
<id>40d21e921a551c61306276dfee10a5529ffe6dbf</id>
<content type='text'>
was branched.

MFC r341755,r342354,r342355,r342386,r342387,r342388,r342526,r342528,
r342530,r342531,r342533,r342534,r342535,r342536,r342659,r345479,
r345485,r345573,r347237,r349849,r349909:

  r341755:
    Copy and clear the reply descriptor atomically.  This prevents concurrency
    in the interrupt handlers (usually due to timeout/error recovery) from
    seeing and processing the same descriptor twice.
  r342354:
    mps(4), mpr(4): Fix lifetime of command buffer for mp?sas_get_sata_identify
  r342355:
    mps(4), mpr(4): remove SATA ID command cancellation hack
  r342386:
    First step in refactoring and fixing the error recovery and task management
    code in the mpr and mps drivers.  Eliminate duplicated code and fix some
    comments.
  r342387:
    Commands for user-initated device resets should come from the high-priority
    allocator.  Prior to this change, they would leak from the normal
    allocator.
  r342388:
    Further refactoring for task management commands.  Also fix a related typo
    from the previous commit.
  r342526:
    Update MPI header files version to 2.00.52 from 2.00.48
  r342528:
    Copy back the Sense data at proper location expected by the application
  r342530:
    Added support for NVMe Task Management
  r342531:
    Add Sea,Aero adapter support
  r342533:
    Enable atomic type descriptor support only for Sea &amp; Aero cards
  r342534:
    On Aero/Sea A0 cards retry MPT Fusion registers reads for max three times
  r342535:
    Update copyright information
  r342536:
    Update mpr driver version to v23.00.00.00-fbsd
  r342659:
    Fix whitespace from r342528
  r345479:
    r329522 created problemss with commands that enter the TIMEDOUT state but
    are successfully returned by the card (usually due to an abort being issued
    as part of timeout recovery). Remove what amounts to an insufficient
    KASSERT, and don't overwrite the state value. State should probably be
    re-designed, and that will be done with a future commit.
  r345485:
    Add event table decoding for SAS Broadcast Primitive events.
  r345573:
    Add missing break statements.  Coverity CID 1400446.
  r347237:
    Add missing newline to debug printf.
  r349849:
    Fix bugs in recovery path and improve cm tracking
  r349909:
    More fully implement the state machine.

Sponsored by: Netflix, Inc
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
was branched.

MFC r341755,r342354,r342355,r342386,r342387,r342388,r342526,r342528,
r342530,r342531,r342533,r342534,r342535,r342536,r342659,r345479,
r345485,r345573,r347237,r349849,r349909:

  r341755:
    Copy and clear the reply descriptor atomically.  This prevents concurrency
    in the interrupt handlers (usually due to timeout/error recovery) from
    seeing and processing the same descriptor twice.
  r342354:
    mps(4), mpr(4): Fix lifetime of command buffer for mp?sas_get_sata_identify
  r342355:
    mps(4), mpr(4): remove SATA ID command cancellation hack
  r342386:
    First step in refactoring and fixing the error recovery and task management
    code in the mpr and mps drivers.  Eliminate duplicated code and fix some
    comments.
  r342387:
    Commands for user-initated device resets should come from the high-priority
    allocator.  Prior to this change, they would leak from the normal
    allocator.
  r342388:
    Further refactoring for task management commands.  Also fix a related typo
    from the previous commit.
  r342526:
    Update MPI header files version to 2.00.52 from 2.00.48
  r342528:
    Copy back the Sense data at proper location expected by the application
  r342530:
    Added support for NVMe Task Management
  r342531:
    Add Sea,Aero adapter support
  r342533:
    Enable atomic type descriptor support only for Sea &amp; Aero cards
  r342534:
    On Aero/Sea A0 cards retry MPT Fusion registers reads for max three times
  r342535:
    Update copyright information
  r342536:
    Update mpr driver version to v23.00.00.00-fbsd
  r342659:
    Fix whitespace from r342528
  r345479:
    r329522 created problemss with commands that enter the TIMEDOUT state but
    are successfully returned by the card (usually due to an abort being issued
    as part of timeout recovery). Remove what amounts to an insufficient
    KASSERT, and don't overwrite the state value. State should probably be
    re-designed, and that will be done with a future commit.
  r345485:
    Add event table decoding for SAS Broadcast Primitive events.
  r345573:
    Add missing break statements.  Coverity CID 1400446.
  r347237:
    Add missing newline to debug printf.
  r349849:
    Fix bugs in recovery path and improve cm tracking
  r349909:
    More fully implement the state machine.

Sponsored by: Netflix, Inc
</pre>
</div>
</content>
</entry>
<entry>
<title>Implement a sysctl to dump in-flight I/O state for debugging.  The tool to</title>
<updated>2018-03-12T05:02:22+00:00</updated>
<author>
<name>Scott Long</name>
<email>scottl@FreeBSD.org</email>
</author>
<published>2018-03-12T05:02:22+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=cf6ea6f27a13a3c125610876954cf4fe4fea7efd'/>
<id>cf6ea6f27a13a3c125610876954cf4fe4fea7efd</id>
<content type='text'>
parse it will be committed in a separate action.

Sponsored by:	Netflix
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
parse it will be committed in a separate action.

Sponsored by:	Netflix
</pre>
</div>
</content>
</entry>
<entry>
<title>Allow physically non-contiguous chain frames allocation in mps(4)/mpr(4).</title>
<updated>2018-02-27T01:48:13+00:00</updated>
<author>
<name>Alexander Motin</name>
<email>mav@FreeBSD.org</email>
</author>
<published>2018-02-27T01:48:13+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=731308d01db4aaf72b112d57a14b99a0c84c8870'/>
<id>731308d01db4aaf72b112d57a14b99a0c84c8870</id>
<content type='text'>
Chain frames required to satisfy all 2K of declared I/Os of 128KB each take
more then a megabyte of a physical memory, all of which existing code tries
allocate as physically contiguous.  This patch removes that physical
contiguousness requirement, leaving only virtual contiguousness.  I was
thinking about other ways of allocation, but the less granular allocation
becomes, the bigger is the overhead and/or complexity, reaching about 100%
overhead if allocate each frame separately.

The patch also bumps the chain frames hard limit from 2K to 16K.  It is more
than enough for the case of default REQ_FRAMES and MAXPHYS (the drivers will
allocate less than that automatically), while in case of increased MAXPHYS
it will control maximal memory usage.

Sponsored by:	iXsystems, Inc.
Differential Revision:	https://reviews.freebsd.org/D14420
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Chain frames required to satisfy all 2K of declared I/Os of 128KB each take
more then a megabyte of a physical memory, all of which existing code tries
allocate as physically contiguous.  This patch removes that physical
contiguousness requirement, leaving only virtual contiguousness.  I was
thinking about other ways of allocation, but the less granular allocation
becomes, the bigger is the overhead and/or complexity, reaching about 100%
overhead if allocate each frame separately.

The patch also bumps the chain frames hard limit from 2K to 16K.  It is more
than enough for the case of default REQ_FRAMES and MAXPHYS (the drivers will
allocate less than that automatically), while in case of increased MAXPHYS
it will control maximal memory usage.

Sponsored by:	iXsystems, Inc.
Differential Revision:	https://reviews.freebsd.org/D14420
</pre>
</div>
</content>
</entry>
<entry>
<title>Improve command lifecycle debugging and detection of problems.</title>
<updated>2018-02-18T16:41:34+00:00</updated>
<author>
<name>Scott Long</name>
<email>scottl@FreeBSD.org</email>
</author>
<published>2018-02-18T16:41:34+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=f0779b0452b4d8e78ae784d0c8a417fd385365c7'/>
<id>f0779b0452b4d8e78ae784d0c8a417fd385365c7</id>
<content type='text'>
Sponsored by:	Netflix
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Sponsored by:	Netflix
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix non-64-bit platform build by printing bus_addr_t values using %#jx</title>
<updated>2018-02-13T16:26:06+00:00</updated>
<author>
<name>Li-Wen Hsu</name>
<email>lwhsu@FreeBSD.org</email>
</author>
<published>2018-02-13T16:26:06+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=92ddc7b86da58a0216caaced8bbeceabed979780'/>
<id>92ddc7b86da58a0216caaced8bbeceabed979780</id>
<content type='text'>
Reviewed by:	slm
Differential Revision:	https://reviews.freebsd.org/D14344
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Reviewed by:	slm
Differential Revision:	https://reviews.freebsd.org/D14344
</pre>
</div>
</content>
</entry>
<entry>
<title>Print out the shared memory queues during initialization</title>
<updated>2018-02-11T20:15:47+00:00</updated>
<author>
<name>Scott Long</name>
<email>scottl@FreeBSD.org</email>
</author>
<published>2018-02-11T20:15:47+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=63b1a33514ec21f8b51e20facb3692a0df180dad'/>
<id>63b1a33514ec21f8b51e20facb3692a0df180dad</id>
<content type='text'>
Sponsored by:	Netflix
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Sponsored by:	Netflix
</pre>
</div>
</content>
</entry>
</feed>
