svn commit: r341930 - stable/11/sys/dev/mlx5/mlx5_core
Hans Petter Selasky
hselasky at FreeBSD.org
Wed Dec 12 12:08:51 UTC 2018
Author: hselasky
Date: Wed Dec 12 12:08:49 2018
New Revision: 341930
URL: https://svnweb.freebsd.org/changeset/base/341930
Log:
MFC r341558:
mlx5: Convert some spaces into tabs and use device_printf() instead of printf().
Sponsored by: Mellanox Technologies
Modified:
stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c
==============================================================================
--- stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Wed Dec 12 12:08:48 2018 (r341929)
+++ stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Wed Dec 12 12:08:49 2018 (r341930)
@@ -1193,7 +1193,7 @@ static int init_one(struct pci_dev *pdev,
priv->pci_dev_data = id->driver_data;
if (prof_sel < 0 || prof_sel >= ARRAY_SIZE(profiles)) {
- printf("mlx5_core: WARN: ""selected profile out of range, selecting default (%d)\n", MLX5_DEFAULT_PROF);
+ device_printf(bsddev, "WARN: selected profile out of range, selecting default (%d)\n", MLX5_DEFAULT_PROF);
prof_sel = MLX5_DEFAULT_PROF;
}
dev->profile = &profiles[prof_sel];
@@ -1208,38 +1208,38 @@ static int init_one(struct pci_dev *pdev,
INIT_LIST_HEAD(&priv->ctx_list);
spin_lock_init(&priv->ctx_lock);
- mutex_init(&dev->pci_status_mutex);
- mutex_init(&dev->intf_state_mutex);
+ mutex_init(&dev->pci_status_mutex);
+ mutex_init(&dev->intf_state_mutex);
err = mlx5_pci_init(dev, priv);
if (err) {
- device_printf((&pdev->dev)->bsddev, "ERR: ""mlx5_pci_init failed %d\n", err);
+ device_printf(bsddev, "ERR: mlx5_pci_init failed %d\n", err);
goto clean_dev;
}
- err = mlx5_health_init(dev);
- if (err) {
- device_printf((&pdev->dev)->bsddev, "ERR: ""mlx5_health_init failed %d\n", err);
- goto close_pci;
- }
+ err = mlx5_health_init(dev);
+ if (err) {
+ device_printf(bsddev, "ERR: mlx5_health_init failed %d\n", err);
+ goto close_pci;
+ }
mlx5_pagealloc_init(dev);
err = mlx5_load_one(dev, priv, true);
if (err) {
- device_printf((&pdev->dev)->bsddev, "ERR: ""mlx5_register_device failed %d\n", err);
+ device_printf(bsddev, "ERR: mlx5_load_one failed %d\n", err);
goto clean_health;
}
mlx5_fwdump_prep(dev);
- pci_save_state(pdev->dev.bsddev);
+ pci_save_state(bsddev);
return 0;
clean_health:
mlx5_pagealloc_cleanup(dev);
- mlx5_health_cleanup(dev);
+ mlx5_health_cleanup(dev);
close_pci:
- mlx5_pci_close(dev, priv);
+ mlx5_pci_close(dev, priv);
clean_dev:
sysctl_ctx_free(&dev->sysctl_ctx);
kfree(dev);
More information about the svn-src-stable-11
mailing list