Commit Graph

35 Commits

Author SHA1 Message Date
riastradh e1ba8d75ab Revert "nvmectl(8): Ensure A divides S before aligned_alloc(A, S)."
C17 lifted this restriction.
2023-07-05 10:58:46 +00:00
riastradh 8d8fdc5894 nvmectl(8): Ensure A divides S before aligned_alloc(A, S).
Required by C11 Sec. 7.22.3.1 The aligned_alloc function, para. 2,
p. 348:

   The value of alignment shall be a valid alignment supported by the
   implementation and the value of size shall be an integral multiple
   of alignment.

XXX pullup-10
2023-07-04 20:40:43 +00:00
lukem f937c412f3 bsd.own.mk: rename to CC_WNO_ADDRESS_OF_PACKED_MEMBER
Provide a single variable
	CC_WNO_ADDRESS_OF_PACKED_MEMBER
with options for both clang and gcc, to replace
	CLANG_NO_ADDR_OF_PACKED_MEMBER
	CC_NO_ADDR_OF_PACKED_MEMBER
	GCC_NO_ADDR_OF_PACKED_MEMBER

Using the convention CC_compilerflag, where compilerflag
is based on the full compiler flag name.
2023-06-03 08:52:53 +00:00
simonb 1145fafc6f In "devlist" mode, exit with a 0 return code if any nvme devices are
found, rather than exiting with 1 return code always.
2023-03-05 23:24:06 +00:00
andvar 19c1490f61 fix some typos in comments. 2023-02-27 22:00:25 +00:00
mlelstv e66f4605a1 Data units read/written are counted in 1000s of 512 bytes.
Convert to human-readable value.
2023-02-02 08:21:32 +00:00
mlelstv 876fd04d2a Fix build on 32bit. 2022-07-31 13:49:23 +00:00
mlelstv fa449f06f2 Report error code (SCT/SC). 2022-07-31 12:11:44 +00:00
andvar 9f4a9600be fix various typos in comments, docs and log messages. 2022-05-24 06:27:59 +00:00
andvar 5a1f79d897 remove one whitespace to align report, misalignment occured after typo fix. 2022-02-17 14:33:25 +00:00
andvar 7f4592413f fix various typos, mainly in comments. 2022-02-16 22:00:55 +00:00
andvar 0f1edf6b40 s/Expceted/Expected/ in log message and s/attribtues/attributes/ in comment. 2022-02-12 23:50:14 +00:00
msaitoh 272a180684 s/offseting/offsetting/ in comment. 2021-11-10 16:02:14 +00:00
jdolecek 6eddb6bb08 add -s option for 'power' command, this instructs the controller to save
the value so it persists resets/whatnot; the NVMe specification lists
this as optional, so this only works if the controller supports it
2020-09-27 18:17:35 +00:00
jdolecek 895d4c1ad7 print current power state and workload as separate values for
'nvmectl power nvme0'
2020-09-27 17:27:07 +00:00
jdolecek 09685c0005 show APSTA support status in identify 2020-09-27 16:45:21 +00:00
mrg cb93b81028 add support for new GCC 9 warnings that may be too much to fix
right now.  new address-of-packed-member and format-overflow
warnings have new GCC_NO_ADDR_OF_PACKED_MEMBER amd
GCC_NO_FORMAT_OVERFLOW variables to remove these warnings.

apply to a bunch of the tree.  mostly, these are real bugs that
should be fixed, but in many cases, only by removing the 'packed'
attribute from some structure that doesn't really need it.  (i
looked at many different ones, and while perhaps 60-80% were
already properly aligned, it wasn't clear to me that the uses
were always coming from sane data vs network alignment, so it
doesn't seem safe to remove packed without careful research for
each affect struct.)  clang already warned (and was not erroring)
for many of these cases, but gcc picked up dozens more.
2020-09-06 07:20:26 +00:00
mrg d6b33fe60a avoid access uninitialised memory, found by gcc8, patch by agc@. 2019-10-04 09:16:38 +00:00
jdolecek b066f5eebd since NVMe 1.2 (which defined the ONCS bit), the bit (4) is whether controller
supports 'Save' field in Set Features, and 'Select' field for Get Features,
not the support for the 'Set Features' command itself
2018-12-01 18:29:19 +00:00
nonaka ca639f32c5 nvmectl(8): Remove some wdc subcommands from man page.
- wdc drive-log
- wdc get-crash-dump
- wdc purge
- wdc purge-monitor
2018-04-18 10:17:54 +00:00
nonaka d2ae75c29e nvmectl(8): fix subcommand usage. 2018-04-18 10:16:22 +00:00
nonaka 6ac76f5b92 nvmectl(8): Add big-endian support.
from FreeBSD nvmecontolr(8) r329824.
2018-04-18 10:11:44 +00:00
nonaka 605c860b16 nvmectl(8): fix wdc command usage. 2018-04-17 15:31:00 +00:00
nonaka 1f5086ec4f nvmectl(8): Sync with FreeBSD nvmecontrol(8) r328763. 2018-04-17 08:54:35 +00:00
jdolecek f24079bab1 use setprogname()/getprogname(), do not hardcode the prognam name in fixed
strings
2018-03-17 11:07:26 +00:00
dholland 32cded6cc9 Typos. 2018-02-08 09:05:16 +00:00
christos 4a2bfb113e sprinkle static and death 2017-05-03 01:37:16 +00:00
wiz 93cd6a62e6 Remove unnecessary Pp. Add missing plural-s. More markup. 2017-04-30 15:59:18 +00:00
nonaka addbc19a7a Added missing file...
> nvmectl(8): sync with FreeBSD HEAD r316105.
>
>  - Expand the SMART / Health Information Log Page (Page 02) printout based on
>    NVM Express 1.2.1 Standard.
>  - Implement Intel-specific log pages.
>  - Implement HGST-specific log pages.
>  - Implement wdc-specific nvme control options.
>  - Add the ability to dump log pages directly in binary to stdout.
2017-04-29 00:08:46 +00:00
nonaka d003492f75 nvmectl(8): sync with FreeBSD HEAD r316105.
- Expand the SMART / Health Information Log Page (Page 02) printout based on
   NVM Express 1.2.1 Standard.
 - Implement Intel-specific log pages.
 - Implement HGST-specific log pages.
 - Implement wdc-specific nvme control options.
 - Add the ability to dump log pages directly in binary to stdout.
2017-04-29 00:06:40 +00:00
nonaka 7f9c3b1be0 128 bit integers are displayed in decimal.
bn.h and bignum.c from netgpg.
2017-02-13 11:16:46 +00:00
nonaka 1c1d2c157d Fix RCS Id. 2016-07-14 10:02:43 +00:00
wiz a6daee9b24 Try improving SYNOPSIS per my understanding of how this works.
Use more markup. Fix some markup.
2016-06-05 09:13:08 +00:00
joerg 0eed2a9437 Mark dead functions. 2016-06-04 20:59:49 +00:00
nonaka cae3c2f471 nvmectl(8): Added NVM Express control utility.
Ported from FreeBSD nvmecontrol(8).
2016-06-04 16:29:35 +00:00