Hi Casey,
I love your patch! Perhaps something to improve:
[auto build test WARNING on nf/master]
[also build test WARNING on linus/master v5.10-rc4 next-20201120]
[cannot apply to nf-next/master security/next-testing]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url:
https://github.com/0day-ci/linux/commits/Casey-Schaufler/LSM-Module-stack...
base:
https://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf.git master
config: x86_64-randconfig-a011-20201120 (attached as .config)
compiler: clang version 12.0.0 (
https://github.com/llvm/llvm-project
3ded927cf80ac519f9f9c4664fef08787f7c537d)
reproduce (this is a W=1 build):
wget
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O
~/bin/make.cross
chmod +x ~/bin/make.cross
# install x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
#
https://github.com/0day-ci/linux/commit/3b464b0251cffe5ac73c81b701fd8d146...
git remote add linux-review
https://github.com/0day-ci/linux
git fetch --no-tags linux-review
Casey-Schaufler/LSM-Module-stacking-for-AppArmor/20201121-044616
git checkout 3b464b0251cffe5ac73c81b701fd8d146664a7a3
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
In file included from drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c:68:
In file included from include/net/xfrm.h:15:
include/linux/audit.h:563:1: error: expected external declaration
+static inline struct audit_context *audit_alloc_local(gfp_t gfpflags)
^
> drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c:6693:30: warning:
shift count >= width of type [-Wshift-count-overflow]
if
(!pci_set_dma_mask(pdev, DMA_BIT_MASK(64))) {
^~~~~~~~~~~~~~~~
include/linux/dma-mapping.h:76:54: note: expanded from macro 'DMA_BIT_MASK'
#define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1))
^ ~~~
drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c:6695:43: warning: shift count >=
width of type [-Wshift-count-overflow]
err = pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(64));
^~~~~~~~~~~~~~~~
include/linux/dma-mapping.h:76:54: note: expanded from macro 'DMA_BIT_MASK'
#define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1))
^ ~~~
2 warnings and 1 error generated.
vim +6693 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6606
1dd06ae8db716e1 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Greg Kroah-Hartman
2012-12-06 6607 static int init_one(struct pci_dev *pdev, const struct pci_device_id
*ent)
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6608 {
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6609 struct net_device *netdev;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6610 struct adapter *adapter;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6611 static int adap_idx = 1;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6612 int s_qpp, qpp, num_seg;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6613 struct port_info *pi;
c8f44affb7244f2 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Michał Mirosław
2011-11-15 6614 bool highdma = false;
d86bd29e0b31f30 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-08-04 6615 enum chip_type chip;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6616 void __iomem *regs;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6617 int func, chip_ver;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6618 u16 device_id;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6619 int i, err;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6620 u32 whoami;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6621
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6622 err = pci_request_regions(pdev, KBUILD_MODNAME);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6623 if (err) {
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6624 /* Just info, some other driver may have claimed the device. */
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6625 dev_info(&pdev->dev, "cannot obtain PCI
resources\n");
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6626 return err;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6627 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6628
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6629 err = pci_enable_device(pdev);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6630 if (err) {
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6631 dev_err(&pdev->dev, "cannot enable PCI device\n");
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6632 goto out_release_regions;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6633 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6634
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6635 regs = pci_ioremap_bar(pdev, 0);
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6636 if (!regs) {
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6637 dev_err(&pdev->dev, "cannot map device
registers\n");
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6638 err = -ENOMEM;
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6639 goto out_disable_device;
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6640 }
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6641
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6642 adapter = kzalloc(sizeof(*adapter), GFP_KERNEL);
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6643 if (!adapter) {
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6644 err = -ENOMEM;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6645 goto out_unmap_bar0;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6646 }
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6647
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6648 adapter->regs = regs;
8203b509c5b7aab drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-10-09 6649 err = t4_wait_dev_ready(regs);
8203b509c5b7aab drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-10-09 6650 if (err < 0)
e729452ec333042 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Christophe JAILLET
2018-02-06 6651 goto out_free_adapter;
8203b509c5b7aab drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-10-09 6652
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6653 /* We control everything through one PF */
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6654 whoami = t4_read_reg(adapter, PL_WHOAMI_A);
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6655 pci_read_config_word(pdev, PCI_DEVICE_ID, &device_id);
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6656 chip = t4_get_chip_type(adapter, CHELSIO_PCI_ID_VER(device_id));
286183147666fb7 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Dan Carpenter
2019-09-25 6657 if ((int)chip < 0) {
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6658 dev_err(&pdev->dev, "Device %d is not supported\n",
device_id);
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6659 err = chip;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6660 goto out_free_adapter;
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6661 }
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6662 chip_ver = CHELSIO_CHIP_VERSION(chip);
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6663 func = chip_ver <= CHELSIO_T5 ?
d86bd29e0b31f30 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-08-04 6664 SOURCEPF_G(whoami) : T6_SOURCEPF_G(whoami);
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6665
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6666 adapter->pdev = pdev;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6667 adapter->pdev_dev = &pdev->dev;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6668 adapter->name = pci_name(pdev);
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6669 adapter->mbox = func;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6670 adapter->pf = func;
016764de8b0d17e drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-03-07 6671 adapter->params.chip = chip;
016764de8b0d17e drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-03-07 6672 adapter->adap_idx = adap_idx;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6673 adapter->msg_enable = DFLT_MSG_ENABLE;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6674 adapter->mbox_log = kzalloc(sizeof(*adapter->mbox_log) +
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6675 (sizeof(struct mbox_cmd) *
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6676 T4_OS_LOG_MBOX_CMDS),
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6677 GFP_KERNEL);
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6678 if (!adapter->mbox_log) {
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6679 err = -ENOMEM;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6680 goto out_free_adapter;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6681 }
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6682 spin_lock_init(&adapter->mbox_lock);
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6683 INIT_LIST_HEAD(&adapter->mlist.list);
aca06eafd09f48c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-09 6684 adapter->mbox_log->size = T4_OS_LOG_MBOX_CMDS;
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6685 pci_set_drvdata(pdev, adapter);
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6686
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6687 if (func != ent->driver_data) {
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6688 pci_disable_device(pdev);
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6689 pci_save_state(pdev); /* to restore SR-IOV later */
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6690 return 0;
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6691 }
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6692
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 @6693 if (!pci_set_dma_mask(pdev, DMA_BIT_MASK(64))) {
c8f44affb7244f2 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Michał Mirosław
2011-11-15 6694 highdma = true;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6695 err = pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(64));
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6696 if (err) {
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6697 dev_err(&pdev->dev, "unable to obtain 64-bit DMA for
"
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6698 "coherent allocations\n");
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6699 goto out_free_adapter;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6700 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6701 } else {
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6702 err = pci_set_dma_mask(pdev, DMA_BIT_MASK(32));
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6703 if (err) {
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6704 dev_err(&pdev->dev, "no usable DMA
configuration\n");
baf5086840ab181 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-16 6705 goto out_free_adapter;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6706 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6707 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6708
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6709 pci_enable_pcie_error_reporting(pdev);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6710 pci_set_master(pdev);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6711 pci_save_state(pdev);
7829451c695e5b7 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2016-08-11 6712 adap_idx++;
29aaee65bc28cc7 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-08-20 6713 adapter->workq = create_singlethread_workqueue("cxgb4");
29aaee65bc28cc7 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-08-20 6714 if (!adapter->workq) {
29aaee65bc28cc7 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-08-20 6715 err = -ENOMEM;
29aaee65bc28cc7 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-08-20 6716 goto out_free_adapter;
29aaee65bc28cc7 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-08-20 6717 }
29aaee65bc28cc7 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-08-20 6718
144be3d9f72fca5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Gavin Shan
2014-01-23 6719 /* PCI device has been enabled */
80f61f19e542aed drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2019-03-04 6720 adapter->flags |= CXGB4_DEV_ENABLED;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6721 memset(adapter->chan_map, 0xff, sizeof(adapter->chan_map));
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6722
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6723 /* If possible, we use PCIe Relaxed Ordering Attribute to deliver
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6724 * Ingress Packet Data to Free List Buffers in order to allow for
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6725 * chipset performance optimizations between the Root Complex and
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6726 * Memory Controllers. (Messages to the associated Ingress Queue
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6727 * notifying new Packet Placement in the Free Lists Buffers will be
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6728 * send without the Relaxed Ordering Attribute thus guaranteeing that
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6729 * all preceding PCIe Transaction Layer Packets will be processed
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6730 * first.) But some Root Complexes have various issues with Upstream
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6731 * Transaction Layer Packets with the Relaxed Ordering Attribute set.
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6732 * The PCIe devices which under the Root Complexes will be cleared the
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6733 * Relaxed Ordering bit in the configuration space, So we check our
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6734 * PCIe configuration space to see if it's flagged with advice
against
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6735 * using Relaxed Ordering.
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6736 */
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6737 if (!pcie_relaxed_ordering_enabled(pdev))
80f61f19e542aed drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2019-03-04 6738 adapter->flags |= CXGB4_ROOT_NO_RELAXED_ORDERING;
b0ba9d5fded9590 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2017-08-15 6739
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6740 spin_lock_init(&adapter->stats_lock);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6741 spin_lock_init(&adapter->tid_release_lock);
e327c225c911529 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-10-29 6742 spin_lock_init(&adapter->win0_lock);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6743
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6744 INIT_WORK(&adapter->tid_release_task,
process_tid_release_list);
881806bc155c0d5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Vipul Pandya
2012-05-18 6745 INIT_WORK(&adapter->db_full_task, process_db_full);
881806bc155c0d5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Vipul Pandya
2012-05-18 6746 INIT_WORK(&adapter->db_drop_task, process_db_drop);
8b7372c101a5f9f drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-03-16 6747 INIT_WORK(&adapter->fatal_err_notify_task, notify_fatal_err);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6748
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6749 err = t4_prep_adapter(adapter);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6750 if (err)
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6751 goto out_free_adapter;
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6752
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6753 if (is_kdump_kernel()) {
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6754 /* Collect hardware state and append to /proc/vmcore */
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6755 err = cxgb4_cudbg_vmcore_add_dump(adapter);
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6756 if (err) {
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6757 dev_warn(adapter->pdev_dev,
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6758 "Fail collecting vmcore device dump, err: %d.
Continuing\n",
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6759 err);
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6760 err = 0;
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6761 }
1dde532dd0520a9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2018-05-02 6762 }
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6763
d14807dd8e7eaa4 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2013-12-03 6764 if (!is_t4(adapter->params.chip)) {
f612b815d75b054 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-01-05 6765 s_qpp = (QUEUESPERPAGEPF0_S +
f612b815d75b054 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-01-05 6766 (QUEUESPERPAGEPF1_S - QUEUESPERPAGEPF0_S) *
b261272276777f0 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-05-27 6767 adapter->pf);
f612b815d75b054 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-01-05 6768 qpp = 1 << QUEUESPERPAGEPF0_G(t4_read_reg(adapter,
f612b815d75b054 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-01-05 6769 SGE_EGRESS_QUEUES_PER_PAGE_PF_A) >> s_qpp);
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6770 num_seg = PAGE_SIZE / SEGMENT_SIZE;
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6771
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6772 /* Each segment size is 128B. Write coalescing is enabled only
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6773 * when SGE_EGRESS_QUEUES_PER_PAGE_PF reg value for the
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6774 * queue is less no of segments that can be accommodated in
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6775 * a page size.
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6776 */
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6777 if (qpp > num_seg) {
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6778 dev_err(&pdev->dev,
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6779 "Incorrect number of egress queues per page\n");
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6780 err = -EINVAL;
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6781 goto out_free_adapter;
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6782 }
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6783 adapter->bar2 = ioremap_wc(pci_resource_start(pdev, 2),
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6784 pci_resource_len(pdev, 2));
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6785 if (!adapter->bar2) {
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6786 dev_err(&pdev->dev, "cannot map device bar2
region\n");
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6787 err = -ENOMEM;
d6ce2628f32271c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2014-09-16 6788 goto out_free_adapter;
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6789 }
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6790 }
22adfe0a85ca380 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Santosh Rastapur
2013-03-14 6791
636f9d371f70f22 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Vipul Pandya
2012-09-26 6792 setup_memwin(adapter);
86e8f2988786cb7 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Vishal Kulkarni
2019-11-05 6793 err = adap_init0(adapter, 0);
5b377d114f2b9ce drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-05-27 6794 #ifdef CONFIG_DEBUG_FS
5b377d114f2b9ce drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-05-27 6795 bitmap_zero(adapter->sge.blocked_fl, adapter->sge.egr_sz);
5b377d114f2b9ce drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-05-27 6796 #endif
636f9d371f70f22 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Vipul Pandya
2012-09-26 6797 setup_memwin_rdma(adapter);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6798 if (err)
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6799 goto out_unmap_bar;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6800
2a485cf7db2815c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-09-08 6801 /* configure SGE_STAT_CFG_A to read WC stats */
2a485cf7db2815c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-09-08 6802 if (!is_t4(adapter->params.chip))
676d6a753066e9b drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-12-23 6803 t4_write_reg(adapter, SGE_STAT_CFG_A, STATSOURCE_T5_V(7) |
676d6a753066e9b drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-12-23 6804 (is_t5(adapter->params.chip) ? STATMODE_V(0) :
676d6a753066e9b drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-12-23 6805 T6_STATMODE_V(0)));
2a485cf7db2815c drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-09-08 6806
b539ea60f5043b9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2018-11-20 6807 /* Initialize hash mac addr list */
b539ea60f5043b9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2018-11-20 6808 INIT_LIST_HEAD(&adapter->mac_hlist);
b539ea60f5043b9 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2018-11-20 6809
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6810 for_each_port(adapter, i) {
ab0367ea42217d4 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2019-11-07 6811 /* For supporting MQPRIO Offload, need some extra
ab0367ea42217d4 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2019-11-07 6812 * queues for each ETHOFLD TIDs. Keep it equal to
ab0367ea42217d4 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2019-11-07 6813 * MAX_ATIDs for now. Once we connect to firmware
ab0367ea42217d4 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2019-11-07 6814 * later and query the EOTID params, we'll come to
ab0367ea42217d4 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2019-11-07 6815 * know the actual # of EOTIDs supported.
ab0367ea42217d4 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2019-11-07 6816 */
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6817 netdev = alloc_etherdev_mq(sizeof(struct port_info),
ab0367ea42217d4 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2019-11-07 6818 MAX_ETH_QSETS + MAX_ATIDS);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6819 if (!netdev) {
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6820 err = -ENOMEM;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6821 goto out_free_dev;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6822 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6823
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6824 SET_NETDEV_DEV(netdev, &pdev->dev);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6825
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6826 adapter->port[i] = netdev;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6827 pi = netdev_priv(netdev);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6828 pi->adapter = adapter;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6829 pi->xact_addr_filt = -1;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6830 pi->port_id = i;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6831 netdev->irq = pdev->irq;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6832
2ed28baa7076083 drivers/net/cxgb4/cxgb4_main.c Michał Mirosław
2011-04-16 6833 netdev->hw_features = NETIF_F_SG | TSO_FLAGS |
2ed28baa7076083 drivers/net/cxgb4/cxgb4_main.c Michał Mirosław
2011-04-16 6834 NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
012475e3c59cbe4 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2019-02-28 6835 NETIF_F_RXCSUM | NETIF_F_RXHASH | NETIF_F_GRO |
d8931847488d250 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2016-09-20 6836 NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_HW_VLAN_CTAG_RX |
c8729cac2a11e4b drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Vishal Kulkarni
2020-06-19 6837 NETIF_F_HW_TC | NETIF_F_NTUPLE;
d0a1299c6bf7d80 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-10 6838
e8d452923ae6cdc drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-24 6839 if (chip_ver > CHELSIO_T5) {
c50ae55e41ee226 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-11 6840 netdev->hw_enc_features |= NETIF_F_IP_CSUM |
c50ae55e41ee226 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-11 6841 NETIF_F_IPV6_CSUM |
c50ae55e41ee226 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-11 6842 NETIF_F_RXCSUM |
c50ae55e41ee226 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-11 6843 NETIF_F_GSO_UDP_TUNNEL |
64f40cdd07e19b5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2019-02-28 6844 NETIF_F_GSO_UDP_TUNNEL_CSUM |
c50ae55e41ee226 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-11 6845 NETIF_F_TSO | NETIF_F_TSO6;
c50ae55e41ee226 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-11 6846
1435d9970378999 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Atul Gupta
2019-01-17 6847 netdev->hw_features |= NETIF_F_GSO_UDP_TUNNEL |
64f40cdd07e19b5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2019-02-28 6848 NETIF_F_GSO_UDP_TUNNEL_CSUM |
1435d9970378999 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Atul Gupta
2019-01-17 6849 NETIF_F_HW_TLS_RECORD;
ad166a8ec26521a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Jakub Kicinski
2020-07-14 6850
ad166a8ec26521a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Jakub Kicinski
2020-07-14 6851 if (adapter->rawf_cnt)
ad166a8ec26521a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Jakub Kicinski
2020-07-14 6852 netdev->udp_tunnel_nic_info = &cxgb_udp_tunnels;
c50ae55e41ee226 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-05-11 6853 }
d0a1299c6bf7d80 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-01-10 6854
c8f44affb7244f2 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Michał Mirosław
2011-11-15 6855 if (highdma)
c8f44affb7244f2 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Michał Mirosław
2011-11-15 6856 netdev->hw_features |= NETIF_F_HIGHDMA;
c8f44affb7244f2 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Michał Mirosław
2011-11-15 6857 netdev->features |= netdev->hw_features;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6858 netdev->vlan_features = netdev->features & VLAN_FEAT;
a8c16e8ed624f24 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rohit Maheshwari
2020-09-10 6859 #if IS_ENABLED(CONFIG_CHELSIO_TLS_DEVICE)
a3ac249a1ab5755 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rohit Maheshwari
2020-06-01 6860 if (pi->adapter->params.crypto & FW_CAPS_CONFIG_TLS_HW) {
a3ac249a1ab5755 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rohit Maheshwari
2020-06-01 6861 netdev->hw_features |= NETIF_F_HW_TLS_TX;
a3ac249a1ab5755 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rohit Maheshwari
2020-06-01 6862 netdev->tlsdev_ops = &cxgb4_ktls_ops;
a3ac249a1ab5755 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rohit Maheshwari
2020-06-01 6863 /* initialize the refcount */
a3ac249a1ab5755 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rohit Maheshwari
2020-06-01 6864 refcount_set(&pi->adapter->chcr_ktls.ktls_refcount, 0);
a3ac249a1ab5755 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rohit Maheshwari
2020-06-01 6865 }
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6866 #endif /* CONFIG_CHELSIO_TLS_DEVICE */
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6867 #if IS_ENABLED(CONFIG_CHELSIO_IPSEC_INLINE)
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6868 if (pi->adapter->params.crypto &
FW_CAPS_CONFIG_IPSEC_INLINE) {
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6869 netdev->hw_enc_features |= NETIF_F_HW_ESP;
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6870 netdev->features |= NETIF_F_HW_ESP;
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6871 netdev->xfrmdev_ops = &cxgb4_xfrmdev_ops;
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6872 }
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6873 #endif /* CONFIG_CHELSIO_IPSEC_INLINE */
76f919ebffe2f66 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ayush Sawal
2020-09-09 6874
01789349ee52e4a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Jiri Pirko
2011-08-16 6875 netdev->priv_flags |= IFF_UNICAST_FLT;
01789349ee52e4a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Jiri Pirko
2011-08-16 6876
d894be57ca92c8a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Jarod Wilson
2016-10-20 6877 /* MTU range: 81 - 9600 */
a047fbae23e1d94 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2017-10-03 6878 netdev->min_mtu = 81; /* accommodate SACK */
d894be57ca92c8a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Jarod Wilson
2016-10-20 6879 netdev->max_mtu = MAX_MTU;
d894be57ca92c8a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Jarod Wilson
2016-10-20 6880
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6881 netdev->netdev_ops = &cxgb4_netdev_ops;
688848b1493a0a5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-06-19 6882 #ifdef CONFIG_CHELSIO_T4_DCB
688848b1493a0a5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-06-19 6883 netdev->dcbnl_ops = &cxgb4_dcb_ops;
688848b1493a0a5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-06-19 6884 cxgb4_dcb_state_init(netdev);
ebddd97afb89cb1 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Ganesh Goudar
2018-08-10 6885 cxgb4_dcb_version_init(netdev);
688848b1493a0a5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Anish Bhatt
2014-06-19 6886 #endif
812034f11628aaa drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-04-06 6887 cxgb4_set_ethtool_ops(netdev);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6888 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6889
ad75b7d32f2517a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2017-10-13 6890 cxgb4_init_ethtool_dump(adapter);
ad75b7d32f2517a drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Rahul Lakkireddy
2017-10-13 6891
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6892 pci_set_drvdata(pdev, adapter);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6893
80f61f19e542aed drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2019-03-04 6894 if (adapter->flags & CXGB4_FW_OK) {
060e0c752b5047e drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-08-02 6895 err = t4_port_init(adapter, func, func, 0);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6896 if (err)
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6897 goto out_free_dev;
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6898 } else if (adapter->params.nports == 1) {
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6899 /* If we don't have a connection to the firmware -- possibly
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6900 * because of an error -- grab the raw VPD parameters so we
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6901 * can set the proper MAC Address on the debug network
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6902 * interface that we've created.
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6903 */
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6904 u8 hw_addr[ETH_ALEN];
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6905 u8 *na = adapter->params.vpd.na;
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6906
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6907 err = t4_get_raw_vpd_params(adapter, &adapter->params.vpd);
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6908 if (!err) {
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6909 for (i = 0; i < ETH_ALEN; i++)
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6910 hw_addr[i] = (hex2val(na[2 * i + 0]) * 16 +
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6911 hex2val(na[2 * i + 1]));
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6912 t4_set_hw_addr(adapter, 0, hw_addr);
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6913 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6914 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6915
80f61f19e542aed drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Arjun Vynipadath
2019-03-04 6916 if (!(adapter->flags & CXGB4_FW_OK))
0eaec62a91ed9d5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2018-07-04 6917 goto fw_attach_fail;
0eaec62a91ed9d5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2018-07-04 6918
098ef6c28a956ba drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-06-05 6919 /* Configure queues and allocate tables now, they can be needed as
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6920 * soon as the first register_netdev completes.
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6921 */
0eaec62a91ed9d5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2018-07-04 6922 err = cfg_queues(adapter);
0eaec62a91ed9d5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2018-07-04 6923 if (err)
0eaec62a91ed9d5 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Casey Leedom
2018-07-04 6924 goto out_free_dev;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6925
3bdb376e6944134 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Kumar Sanghvi
2017-10-18 6926 adapter->smt = t4_init_smt();
3bdb376e6944134 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Kumar Sanghvi
2017-10-18 6927 if (!adapter->smt) {
3bdb376e6944134 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Kumar Sanghvi
2017-10-18 6928 /* We tolerate a lack of SMT, giving up some functionality */
3bdb376e6944134 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Kumar Sanghvi
2017-10-18 6929 dev_warn(&pdev->dev, "could not allocate SMT,
continuing\n");
3bdb376e6944134 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Kumar Sanghvi
2017-10-18 6930 }
3bdb376e6944134 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Kumar Sanghvi
2017-10-18 6931
5be9ed8d49754c2 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c Hariprasad Shenai
2015-07-07 6932 adapter->l2t = t4_init_l2t(adapter->l2t_start,
adapter->l2t_end);
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6933 if (!adapter->l2t) {
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6934 /* We tolerate a lack of L2T, giving up some functionality */
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6935 dev_warn(&pdev->dev, "could not allocate L2T,
continuing\n");
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6936 adapter->params.offload = 0;
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6937 }
b8ff05a9c3237f6 drivers/net/cxgb4/cxgb4_main.c Dimitris Michailidis
2010-04-01 6938
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org