1
0
Fork 0
mirror of synced 2025-03-06 20:59:54 +01:00
linux/drivers/infiniband/hw/hfi1
Linus Torvalds 71a7507afb Driver Core changes for 6.2-rc1
Here is the set of driver core and kernfs changes for 6.2-rc1.
 
 The "big" change in here is the addition of a new macro,
 container_of_const() that will preserve the "const-ness" of a pointer
 passed into it.
 
 The "problem" of the current container_of() macro is that if you pass in
 a "const *", out of it can comes a non-const pointer unless you
 specifically ask for it.  For many usages, we want to preserve the
 "const" attribute by using the same call.  For a specific example, this
 series changes the kobj_to_dev() macro to use it, allowing it to be used
 no matter what the const value is.  This prevents every subsystem from
 having to declare 2 different individual macros (i.e.
 kobj_const_to_dev() and kobj_to_dev()) and having the compiler enforce
 the const value at build time, which having 2 macros would not do
 either.
 
 The driver for all of this have been discussions with the Rust kernel
 developers as to how to properly mark driver core, and kobject, objects
 as being "non-mutable".  The changes to the kobject and driver core in
 this pull request are the result of that, as there are lots of paths
 where kobjects and device pointers are not modified at all, so marking
 them as "const" allows the compiler to enforce this.
 
 So, a nice side affect of the Rust development effort has been already
 to clean up the driver core code to be more obvious about object rules.
 
 All of this has been bike-shedded in quite a lot of detail on lkml with
 different names and implementations resulting in the tiny version we
 have in here, much better than my original proposal.  Lots of subsystem
 maintainers have acked the changes as well.
 
 Other than this change, included in here are smaller stuff like:
   - kernfs fixes and updates to handle lock contention better
   - vmlinux.lds.h fixes and updates
   - sysfs and debugfs documentation updates
   - device property updates
 
 All of these have been in the linux-next tree for quite a while with no
 problems, OTHER than some merge issues with other trees that should be
 obvious when you hit them (block tree deletes a driver that this tree
 modifies, iommufd tree modifies code that this tree also touches).  If
 there are merge problems with these trees, please let me know.
 
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 -----BEGIN PGP SIGNATURE-----
 
 iG0EABECAC0WIQT0tgzFv3jCIUoxPcsxR9QN2y37KQUCY5wz3A8cZ3JlZ0Brcm9h
 aC5jb20ACgkQMUfUDdst+yks0ACeKYUlVgCsER8eYW+x18szFa2QTXgAn2h/VhZe
 1Fp53boFaQkGBjl8mGF8
 =v+FB
 -----END PGP SIGNATURE-----

Merge tag 'driver-core-6.2-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core

Pull driver core updates from Greg KH:
 "Here is the set of driver core and kernfs changes for 6.2-rc1.

  The "big" change in here is the addition of a new macro,
  container_of_const() that will preserve the "const-ness" of a pointer
  passed into it.

  The "problem" of the current container_of() macro is that if you pass
  in a "const *", out of it can comes a non-const pointer unless you
  specifically ask for it. For many usages, we want to preserve the
  "const" attribute by using the same call. For a specific example, this
  series changes the kobj_to_dev() macro to use it, allowing it to be
  used no matter what the const value is. This prevents every subsystem
  from having to declare 2 different individual macros (i.e.
  kobj_const_to_dev() and kobj_to_dev()) and having the compiler enforce
  the const value at build time, which having 2 macros would not do
  either.

  The driver for all of this have been discussions with the Rust kernel
  developers as to how to properly mark driver core, and kobject,
  objects as being "non-mutable". The changes to the kobject and driver
  core in this pull request are the result of that, as there are lots of
  paths where kobjects and device pointers are not modified at all, so
  marking them as "const" allows the compiler to enforce this.

  So, a nice side affect of the Rust development effort has been already
  to clean up the driver core code to be more obvious about object
  rules.

  All of this has been bike-shedded in quite a lot of detail on lkml
  with different names and implementations resulting in the tiny version
  we have in here, much better than my original proposal. Lots of
  subsystem maintainers have acked the changes as well.

  Other than this change, included in here are smaller stuff like:

   - kernfs fixes and updates to handle lock contention better

   - vmlinux.lds.h fixes and updates

   - sysfs and debugfs documentation updates

   - device property updates

  All of these have been in the linux-next tree for quite a while with
  no problems"

* tag 'driver-core-6.2-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (58 commits)
  device property: Fix documentation for fwnode_get_next_parent()
  firmware_loader: fix up to_fw_sysfs() to preserve const
  usb.h: take advantage of container_of_const()
  device.h: move kobj_to_dev() to use container_of_const()
  container_of: add container_of_const() that preserves const-ness of the pointer
  driver core: fix up missed drivers/s390/char/hmcdrv_dev.c class.devnode() conversion.
  driver core: fix up missed scsi/cxlflash class.devnode() conversion.
  driver core: fix up some missing class.devnode() conversions.
  driver core: make struct class.devnode() take a const *
  driver core: make struct class.dev_uevent() take a const *
  cacheinfo: Remove of_node_put() for fw_token
  device property: Add a blank line in Kconfig of tests
  device property: Rename goto label to be more precise
  device property: Move PROPERTY_ENTRY_BOOL() a bit down
  device property: Get rid of __PROPERTY_ENTRY_ARRAY_EL*SIZE*()
  kernfs: fix all kernel-doc warnings and multiple typos
  driver core: pass a const * into of_device_uevent()
  kobject: kset_uevent_ops: make name() callback take a const *
  kobject: kset_uevent_ops: make filter() callback take a const *
  kobject: make kobject_namespace take a const *
  ...
2022-12-16 03:54:54 -08:00
..
affinity.c RDMA/hfi: Decrease PCI device reference count in error path 2022-11-22 09:53:36 +02:00
affinity.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
aspm.c IB/hfi1: Reduce excessive aspm inlines 2019-06-28 22:34:26 -03:00
aspm.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
chip.c RDMA/hfi1: fix repeated words in comments 2022-09-20 14:06:49 +03:00
chip.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
chip_registers.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
common.h RDMA/hfi1: Remove all traces of diagpkt support 2022-05-24 15:08:32 -03:00
debugfs.c RDMA/hfi1: Delete useless module.h include 2022-01-28 13:03:12 -04:00
debugfs.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
device.c driver core: make struct class.devnode() take a const * 2022-11-24 17:12:27 +01:00
device.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
driver.c RDMA/hfi1: use sysfs_emit() to instead of scnprintf() 2022-12-07 11:04:17 +02:00
efivar.c IB/hf1: Fix typo in comment 2022-05-24 11:24:57 -03:00
efivar.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
eprom.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
eprom.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
exp_rcv.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
exp_rcv.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
fault.c RDMA/hfi1: Delete useless module.h include 2022-01-28 13:03:12 -04:00
fault.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
file_ops.c IB: move from strlcpy with unused retval to strscpy 2022-08-21 14:18:02 +03:00
firmware.c RDMA/hfi1: Fix error return code in parse_platform_config() 2022-12-04 15:26:58 +02:00
hfi.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
init.c RDMA/hfi1: don't pass bogus GFP_ flags to dma_alloc_coherent 2022-11-21 09:35:52 +01:00
intr.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
iowait.c RDMA/hw/hfi1/iowait: Demote half-completed kernel-doc and fix formatting issue in another 2021-01-28 15:42:26 -04:00
iowait.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
ipoib.h IB/hfi1: Fix alloc failure with larger txqueuelen 2022-01-28 11:12:15 -04:00
ipoib_main.c IB/hfi1: Fix tstats alloc and dealloc 2022-01-28 11:12:15 -04:00
ipoib_rx.c IB/hfi1: Use skb_put_data() instead of skb_put/memcpy pair 2022-09-27 10:43:10 -03:00
ipoib_tx.c IB/hfi1: switch to netif_napi_add_tx() 2022-07-17 21:29:46 +03:00
Kconfig RDMA/hfi1: Depend on !UML 2022-07-18 13:40:38 +03:00
mad.c IB/hfi1: Replace 1-element array with singleton 2022-11-18 19:54:11 -04:00
mad.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
Makefile IB/hfi1: Add functions to receive accelerated ipoib packets 2020-05-21 11:23:56 -03:00
mmu_rb.c RDMA/hfi1: Fix use-after-free bug for mm struct 2022-04-08 15:40:06 -03:00
mmu_rb.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
msix.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
msix.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
netdev.h IB/hfi1: Rework AIP and VNIC dummy netdev usage 2021-04-13 13:54:56 -03:00
netdev_rx.c IB/hfi1: Switch to netif_napi_add() 2022-12-01 11:09:48 +02:00
opa_compat.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
opfn.c IB/hfi1: Add TID RDMA retry timer 2019-02-05 18:07:43 -05:00
opfn.h IB/hfi1: Make opfn.h self sufficient 2019-04-24 11:31:49 -03:00
pcie.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
pio.c IB/hfi1: Correctly move list in sc_disable() 2022-10-19 10:06:07 +03:00
pio.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
pio_copy.c RDMA/hfi1: Fix typo in comment 2022-06-07 11:57:26 +03:00
platform.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
platform.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
qp.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
qp.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
qsfp.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
qsfp.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
rc.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
rc.h IB/hfi1: Delay the release of destination mr for TID RDMA WRITE DATA 2019-04-03 15:27:30 -03:00
ruc.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
sdma.c RDMA/hfi1: Prevent use of lock before it is initialized 2022-05-24 14:52:47 -03:00
sdma.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
sdma_txreq.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
sysfs.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
tid_rdma.c treewide: use get_random_u32() when possible 2022-10-11 17:42:58 -06:00
tid_rdma.h IB/hfi1: Calculate flow weight based on QP MTU for TID RDMA 2019-11-06 13:15:36 -04:00
trace.c IB/hfi1: make hist static 2021-09-08 08:33:04 -03:00
trace.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
trace_ctxts.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
trace_dbg.h tracing/IB/hfi1: Use the new __vstring() helper 2022-07-15 17:44:40 -04:00
trace_ibhdrs.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
trace_iowait.h IB/hfi1: Add static trace for iowait 2018-09-30 19:21:12 -06:00
trace_misc.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
trace_mmu.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
trace_rc.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
trace_rx.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
trace_tid.h treewide: Add missing semicolons to __assign_str uses 2021-06-30 09:19:14 -04:00
trace_tx.h IB/hfi1: Add ring consumer and producers traces 2021-09-27 20:06:42 -03:00
uc.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
ud.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
user_exp_rcv.c RDMA/hfi1: Use struct_size() and flex_array_size() helpers 2021-09-27 20:15:54 -03:00
user_exp_rcv.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
user_pages.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
user_sdma.c IB/hfi1: Use bitmap_zalloc() when applicable 2021-11-29 14:33:55 -04:00
user_sdma.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
verbs.c RDMA/hfi1: Remove the unneeded result variable 2022-09-05 15:14:31 +03:00
verbs.h IB/hfi1: remove rc_only_opcode and uc_only_opcode declarations 2022-09-20 20:13:10 +03:00
verbs_txreq.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
verbs_txreq.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
vnic.h RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
vnic_main.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00
vnic_sdma.c RDMA/hfi1: Convert to SPDX identifier 2021-08-25 14:56:48 -03:00