Commit Graph

288498 Commits

Author SHA1 Message Date
Vincenzo Maffione
ee5804da11 netmap: fix unit tests
After ad874544d9, interface name
validation has been removed, resulting in two unit tests failures.
Drop the failing tests since they no longer apply.

Reported by:	markj
2023-12-29 07:46:46 +00:00
Colin Percival
8a735ffdf0 EC2: Bump AMI size to 6 GB
This week's cloud-init ZFS snapshots ran out of disk space.
2023-12-28 14:24:46 -08:00
John Baldwin
e7300a8f63 OptionalObsoleteFiles.inc: Add libnss_tacplus_p.a as an old profiled library
Noticed this was still present after upgrading a 12.x stable host to
14.0 stable.
2023-12-28 14:20:54 -08:00
Kenneth D. Merry
40a492d38e camcontrol: Add a sense subcommand
As the name suggests, this sends a SCSI REQUEST SENSE to a device,
and prints out decoded sense information.  It can also print out a
hexdump of the sense data.

sbin/camcontrol/camcontrol.c:
	Add the new sense subcommand.

sbin/camcontrol/camcontrol.8:
	Document camcontrol sense.

Sponsored by:	Spectra Logic
Reviewed by:	mav
MFC after:	3 days
Differential Revision:  https://reviews.freebsd.org/D43225
2023-12-28 16:23:16 -05:00
Lexi Winter
f79b200b6a nfsstat: make -q work without -e/-E
MFC after:	2 weeks
Pull Request:	https://github.com/freebsd/freebsd-src/pull/961
2023-12-28 13:27:07 -07:00
Mark Johnston
c63dda466a atrtc: Add a required include
PR:		275867
MFC after:	1 week
2023-12-28 15:17:32 -05:00
John Baldwin
f7d5900aa0 sys: Style fix for M_EXT | M_EXTPG
Add a space around the | operator in places testing for either M_EXT
or M_EXTPG.

Reviewed by:	imp, glebius
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D43216
2023-12-28 11:17:59 -08:00
John Baldwin
854e1fd692 mbuf.9: Document mtodo
mtodo() accepts an mbuf and offset and returns a void * pointer to the
requested offset into the mbuf's associated data.  Similar to mtod(),
no bounds checking is performed.

Reviewed by:	imp, markj
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D43215
2023-12-28 11:17:45 -08:00
Joerg Pulz
10ed63fc06 isp(4): Rework firmware handling/loading
Correctly identify the active firmware in flash on adapters with
primary and secondary firmware region in flash.
Correctly identify the active NVRAM on adapters with primary
and secondary NVRAM region in flash.

Loading ispfw(4) moved from isp_pci_attach() to isp_reset().
Drop the reference to ispfw(4) after using it so one can kldunload(8) it.
New isp_load_ram() function to load either ispfw(4) or flash firmware
into RISC's RAM.
New functions to read data from flash. The old ones will be removed later.
A bunch of new helper functions to identify and validate active flash
regions for firmware, auxiliary and NVRAM.
Overhaul ISP_FW_* macros and make use of it when comparing firmware
versions. We can handle firmware versions up to 255.255.255.

Firmware load priority slightly changed:
For 27xx and newer adapters:
- load ispfw(4) firmware
- request (active) flash firmware information
- compare version numbers of ispfw(4) and flash firmware
- load firmware with highest version into RISC's RAM
- if loading ispfw(4) is disabled or failed - load firmware from flash
- if everything else fails use MBOX_LOAD_FLASH_FIRMWARE as fallback

For 26xx and older adapters nothing changed:
- load ispfw(4) firmware and load it into RISC's RAM
- if loading ispfw(4) is disabled or failed use MBOX_EXEC_FIRMWARE
- for 26xx a preceding MBOX_LOAD_FLASH_FIRMWARE is used

New read only sysctl(8)'s:
 dev.isp.N.fw_version_run: the firmware version actually running
 dev.isp.N.fw_version_ispfw: the firmware version provided by ispfw(4)
 dev.isp.N.fw_version_flash: the (active) firmware version in flash

While here:
  - firmware attribute handling/parsing reworked
    + renamed defines from ISP2400_FW_ATTR_* to ISP_FW_ATTR_*
    + changed values to match new handling/parsing
    + added some more attributes
  - enable FLT support on 26xx based adapters
  - log level adjustments
  - new function return status codes (some for now, some for later use)
  - some minor style changes

Tested and approved to work on real hardware with:
  - Qlogic ISP 2532 (QLogic QLE2560 8Gb FC Adapter)
  - Qlogic ISP 2031 (QLogic QLE2662 16Gbit 2Port FC Adapter)
  - Qlogic ISP 2722 (QLogic QLE2690 16Gb FC Adapter)
  - Qlogic ISP 2812 (QLogic QLE2772 32Gbit 2Port FC Adapter)

PR:		273263
Reviewed by:	mav
Pull Request:	https://github.com/freebsd/freebsd-src/pull/877
MFC after:	1 month
Sponsored by:	Technical University of Munich
2023-12-28 13:33:07 -05:00
Joerg Pulz
b0c6b06836 ispfw(4): Update and add firmware
Update 25xx firmware: version 8.8.207
Add 26xx firmware: version 8.8.231
Add 27xx firmware: version 9.12.0
Add 28xx firmware: version 9.12.1

Remove BUGS section from manpage as we now have firmware for
all supported controllers.

PR:		273263
MFC after:	1 month
Pull Request:	https://github.com/freebsd/freebsd-src/pull/877
Sponsored by:	Technical University of Munich
2023-12-28 13:31:56 -05:00
Mark Johnston
d068ea16e3 cam: Let cam_periph_unmapmem() return an error
As of commit b059686a71, cam_periph_unmapmem() can legitimately fail
if the copyout() operation fails.  However, this failure was never
signaled to upper layers.  In practice it is unlikely to occur
since cap_periph_mapmem() would most likely fail in such
circumstances anyway, but an error is nonetheless possible.

However, some code reading revealed a few paths where the return value
of cam_periph_mapmem() is not checked, and this is definitely a bug.
Add error checking there and let cam_periph_unmapmem() return errors
from copyout().

Reviewed by:	dab, mav
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D43201
2023-12-28 12:36:15 -05:00
Warner Losh
23699ff23c Revert "vtnet: Adjust rx buffer so IP header 32-bit aligned"
This reverts commit 9e6d11ce9a.

This wasn't right to start with...

Requested by: markj
2023-12-28 10:22:23 -07:00
Warner Losh
8ee1cc4a7f Revert "vtnet: Better adjust for ethernet alignment."
This reverts commit e9da71cd35.

This was inadvertantly pushed and turns out ot be not quite right.

Requested by: markj
2023-12-28 10:22:14 -07:00
Wolfram Schneider
ffd76b1f30 use long manpage URL (broken in last commit)
Reported by:	pstef
2023-12-28 15:58:56 +00:00
rilysh
5f71f9636e CONTRIBUTING.md: fix typo from commmit to commit
Signed-off-by: rilysh <nightquick@proton.me>
Pull-request: https://github.com/freebsd/freebsd-src/pull/960
2023-12-28 10:01:03 -05:00
Osama Abboud
4e2688cc76 ena: Update driver version to v2.7.0
Features:
* Introduce customer and SRD metrics through sysctl
* Introduce spreading IRQs to CPUs capability using sysctl
* Upgrade ena-com to v2.7.0

Bug Fixes:
* Remove outdated APIs

Minor Changes:
* Introduce a shared stats sample interval for all stats

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:56:43 +00:00
Osama Abboud
246aa27324 ena: Update the license dating to 2023
Some of the files are using outdated linceses.
Update the license to be 2023.

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:56:36 +00:00
Osama Abboud
36d42c862f ena: Support srd metrics with sysctl
This commit introduces SRD metrics through sysctl.
The metrics can be queried using the following sysctl node:
sysctl dev.ena.<device index>.ena_srd_info

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:56:30 +00:00
Osama Abboud
f97993ad7b ena: Support customer metric with sysctl
This commit adds sysctl support for customer metrics.
Different customer metrics can be found in the following sysctl node:
sysctl dev.ena.<device index>.customer_metrics

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:56:24 +00:00
Osama Abboud
5b925280d9 ena: Introduce shared sample interval for all stats
Rename sample_interval node to stats_sample_interval and move
it up in the sysctl tree to make it clear that it's relevant for
all the stats and not only ENI metrics (Currently, sample interval node
is found under eni_metrics node).

Path to node:
dev.ena.<device_index>.stats_sample_interval

Once this parameter is set it will set the sample interval for all the
stats node including SRD/customer metrics.

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:56:18 +00:00
Osama Abboud
2835752e07 ena: Remove CQ tail pointer update API
This commit removes the usage of this API from the freebsd driver since
the relevant functionality is not supported by the device.

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:56:11 +00:00
Osama Abboud
72e34ebdd0 ena: Update ena_com_update_intr_reg API usage
This commit fixes the usage of this function to be compatible with the
new API introduced by ena-com update to v2.7.0

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:56:05 +00:00
Arthur Kiyanovski
9272e45c04 ena: Change measurement unit of time since last tx cleanup to ms
This commit:
1. Sets the time since last cleanup to milliseconds.
2. Fixes incorrect indentations.

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:55:57 +00:00
Osama Abboud
f9e1d94710 ena: Add sysctl support for spreading IRQs
This commit allows spreading IO IRQs over different CPUs through sysctl.
Two sysctl nodes are introduced:
1- base_cpu: servers as the first CPU to which the first IO IRQ
will be bound.
2- cpu_stride: sets the distance between every two CPUs to which every
two consecutive IO IRQs are bound.

For example for doing the following IO IRQs / CPU binding:

IRQ idx |  CPU
----------------
   1    |   0
   2    |   2
   3    |   4
   4    |   6

Run the following commands:
sysctl dev.ena.<device index>.irq_affinity.base_cpu=0
sysctl dev.ena.<device_index>.irq_affinity.cpu_stride=2

Also introduced rss_enabled field, which is intended to replace
'#ifdef RSS' in multiple places, in order to prevent code duplication.

We want to bind interrupts to CPUs in case of rss set OR in case
the newly defined sysctl paremeter is set. This requires to remove a
couple of '#ifdef RSS' as well in the structs, since we'll be using the
relevant parameters in the CPU binding code.

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:55:47 +00:00
Arthur Kiyanovski
adfed2d835 ena: Upgrade ena-com to freebsd v2.7.0
Merge commit '04cf7cee5ae0c6bb29eb21ce85bab7ca7386a95f'

Approved by: cperciva (mentor)
MFC after: 2 weeks
Sponsored by: Amazon, Inc.
2023-12-28 13:52:31 +00:00
Osama Abboud
04cf7cee5a ena: Upgrade ena-com to freebsd v2.7.0
This commit introduces a number of infrastructures in ena-com, some of
which are being used as of ENA v2.7.0 while other certain infrastructure
assets have been made available for potential future application.

Upgrade ena-com to include the following changes:

* Introduce customer metrics infrastructures
* Introduce SRD metrics infrastructures
* Remove unused fields from ena_com_io_cq and ena_com_io_sq structs
* Minor rework of ena_com_fill_hash_function
* Introduce PHC infrastructures
* Update the licenses for ena-com files
* Delete duplicate *_defs.h found in ena-com and ena_defs directories
* Add validation for completion descriptors consistency
* Move ena_fbsd_log.h file to ena_plat.h

Approved by: cperciva (mentor)
Sponsored by: Amazon, Inc.
2023-12-28 13:29:14 +00:00
Dimitry Andric
e77a1bb275 Reorganize libclang_rt Makefile and make more lib/arch combos available
Upstream has made more clang runtime libraries available for more
architectures, so add them. To make this easier, split up subdir lists
into functional parts (asan, tsan, etc), and put each architecture into
its own .if block.

Effectively, this adds the following libraries for aarch64: asan, cfi,
fuzzer, msan, safestack, stats, tsan, ubsan, xray.

PR:		262706
MFC after:	3 days
2023-12-28 13:57:41 +01:00
Wolfram Schneider
789480702e support spaces in filenames
PR:		275978
MFC after:	1 week
2023-12-28 10:50:29 +00:00
Wolfram Schneider
271887ec35 update manpage URL 2023-12-28 10:48:04 +00:00
Wolfram Schneider
f8952e4ee0 update homepage for FreeBSD Manual Pages (again) 2023-12-28 07:11:38 +00:00
Alex
e4183f1745 geom/journal: Fix typos
Fixed a few typos.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/884
2023-12-27 23:42:03 -07:00
Warner Losh
4b817fc1f0 CONTRIBUTING.md: Fix typos
Fix my own typoes.

Noticed by: kevans, cperciva

Sponsored by:		Netflix
2023-12-27 23:25:53 -07:00
Warner Losh
e9da71cd35 vtnet: Better adjust for ethernet alignment.
Move adjustment of the mbuf from where we allocate it to where we are
about to queue it to the device. Do this only on those platforms that
require it. This allows us to receive an entire jumbo frame on other
platforms. It also doesn't make the adjustment on subsequent frames when
we queue mulitple mbufs for LRO operations.

For the normal use case on armv7, there's no difference because we only
ever allocate one mbuf. However, for the LRO cases it increases what's
available in LRO. It also ensure that we get enough mbufs in those cases
as well (though I have no ability to test this on a LRO scenario with
armv7).

This has the side effect of reverting 527b62e37e68.

Fixes:			527b62e37e68
Sponsored by:		Netflix
2023-12-27 23:25:53 -07:00
Jose Luis Duran
b8856bd2d6 mtree: Add missing directories to BSD.tests.dist
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/912
2023-12-27 22:26:31 -07:00
Jose Luis Duran
b8e385d35c mtree: Sort BSD.tests.dist
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/912
2023-12-27 22:26:30 -07:00
Jose Luis Duran
1ed17d86bb mtree: Add missing directories to BSD.root.dist
While here, align to the output produced by mtree.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/912
2023-12-27 22:26:29 -07:00
Jose Luis Duran
5b7f73ce16 mtree: Add missing directories generated by certctl
PR: 255639
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/912
2023-12-27 22:26:28 -07:00
Jose Luis Duran
20d685623f mtree: Properly sort entries
Reduce the diff with the output generated by mtree.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/912
2023-12-27 22:26:27 -07:00
Jose Luis Duran
0888bac4f6 mtree: Use spaces not tabs
The indentation generated by mtree -j uses spaces, not tabs.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/912
2023-12-27 22:26:27 -07:00
Jose Luis Duran
0a41a6681d mtree: Update mtree flags in README file
- Add -b (suppress blank lines before directories).
- The equivalent of `-i` in fmtree is `-j` in mtree (nmtree) (indent the
  output 4 spaces).
- Add `-F freebsd9` compatibility flavor (print the closing `..` at the
  end).

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/912
2023-12-27 22:26:26 -07:00
Elyes Haouas
44cf844b16 tree: Use 1 semicolon at the end of a statement
Signed-off-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/889
2023-12-27 21:05:56 -07:00
Elyes Haouas
540be39b0b tree: Use 1 semicolon at the end of a statement
Signed-off-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/889
2023-12-27 21:05:47 -07:00
Warner Losh
05e5852d1b CONTRIBUTING.md: add note about upstreams.
Sponsored by:		Netflix
2023-12-27 20:40:57 -07:00
Jose Luis Duran
0fef54255b route6d: Fix typo (triple S)
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/955
2023-12-27 20:24:32 -07:00
Jose Luis Duran
a6889c1d5c bmake: Fix typo (triple S)
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/955
2023-12-27 20:24:32 -07:00
Jose Luis Duran
9c5f4c4f95 sys: Fix typo (triple S)
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/955
2023-12-27 20:24:32 -07:00
Jose Luis Duran
c43829a757 netpfil: Fix typo (triple S)
While here, align the comment box.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/955
2023-12-27 20:24:32 -07:00
Jose Luis Duran
3e8d829747 net: Fix typo (triple S)
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/955
2023-12-27 20:24:32 -07:00
Jose Luis Duran
8b007a7435 fuse: Fix typo (triple S)
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/955
2023-12-27 20:24:32 -07:00
Jose Luis Duran
6cd48617c4 qat: Fix typo (triple S)
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/955
2023-12-27 20:24:31 -07:00