Commit 5f153b63 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'ntb-6.12' of https://github.com/jonmason/ntb

Pull PCIe non-transparent bridge updates from Jon Mason:
 "Bug fixes for intel ntb driver debugfs, use after free in switchtec
  driver, ntb transport rx ring buffers. Also, cleanups in printks,
  kernel-docs, and idt driver comment"

* tag 'ntb-6.12' of https://github.com/jonmason/ntb:
  ntb: Force physically contiguous allocation of rx ring buffers
  ntb: ntb_hw_switchtec: Fix use after free vulnerability in switchtec_ntb_remove due to race condition
  ntb: idt: Fix the cacography in ntb_hw_idt.c
  NTB: epf: don't misuse kernel-doc marker
  NTB: ntb_transport: fix all kernel-doc warnings
  ntb: Constify struct bus_type
  ntb_perf: Fix printk format
  ntb: intel: Fix the NULL vs IS_ERR() bug for debugfs_create_dir()
parents d7dfb07d 061a785a
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -72,7 +72,7 @@ MODULE_VERSION(DRIVER_VERSION);
MODULE_AUTHOR(DRIVER_AUTHOR);
MODULE_DESCRIPTION(DRIVER_DESCRIPTION);

static struct bus_type ntb_bus;
static const struct bus_type ntb_bus;
static void ntb_dev_release(struct device *dev);

int __ntb_register_client(struct ntb_client *client, struct module *mod,
@@ -298,7 +298,7 @@ static void ntb_dev_release(struct device *dev)
	complete(&ntb->released);
}

static struct bus_type ntb_bus = {
static const struct bus_type ntb_bus = {
	.name = "ntb",
	.probe = ntb_probe,
	.remove = ntb_remove,
+1 −1
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0
/**
/*
 * Host side endpoint driver to implement Non-Transparent Bridge functionality
 *
 * Copyright (C) 2020 Texas Instruments
+1 −1
Original line number Diff line number Diff line
@@ -2547,7 +2547,7 @@ static void idt_deinit_dbgfs(struct idt_ntb_dev *ndev)
 */

/*
 * idt_check_setup() - Check whether the IDT PCIe-swtich is properly
 * idt_check_setup() - Check whether the IDT PCIe-switch is properly
 *		       pre-initialized
 * @pdev:	Pointer to the PCI device descriptor
 *
+1 −1
Original line number Diff line number Diff line
@@ -778,7 +778,7 @@ static void ndev_init_debugfs(struct intel_ntb_dev *ndev)
		ndev->debugfs_dir =
			debugfs_create_dir(pci_name(ndev->ntb.pdev),
					   debugfs_dir);
		if (!ndev->debugfs_dir)
		if (IS_ERR(ndev->debugfs_dir))
			ndev->debugfs_info = NULL;
		else
			ndev->debugfs_info =
+1 −0
Original line number Diff line number Diff line
@@ -1554,6 +1554,7 @@ static void switchtec_ntb_remove(struct device *dev)
	switchtec_ntb_deinit_db_msg_irq(sndev);
	switchtec_ntb_deinit_shared_mw(sndev);
	switchtec_ntb_deinit_crosslink(sndev);
	cancel_work_sync(&sndev->check_link_status_work);
	kfree(sndev);
	dev_info(dev, "ntb device unregistered\n");
}
Loading