From: Leon Romanovsky <leon@kernel.org>
To: Gal Pressman <galpress@amazon.com>
Cc: kbuild test robot <lkp@intel.com>, Jason Gunthorpe <jgg@ziepe.ca>,
Doug Ledford <dledford@redhat.com>,
kbuild-all@lists.01.org, linux-rdma@vger.kernel.org,
Alexander Matushevsky <matua@amazon.com>,
Firas JahJah <firasj@amazon.com>, Guy Tzalik <gtzalik@amazon.com>
Subject: Re: [PATCH for-next 2/2] RDMA/efa: Report host information to the device
Date: Sun, 10 May 2020 18:11:02 +0300 [thread overview]
Message-ID: <20200510151102.GC199306@unreal> (raw)
In-Reply-To: <2b98035f-aa55-1b11-7012-fddca885ba4f@amazon.com>
On Sun, May 10, 2020 at 05:40:21PM +0300, Gal Pressman wrote:
> On 10/05/2020 16:42, kbuild test robot wrote:
> > Hi Gal,
> >
> > I love your patch! Yet something to improve:
> >
> > [auto build test ERROR on rdma/for-next]
> > [also build test ERROR on v5.7-rc4 next-20200508]
> > [if your patch is applied to the wrong git tree, please drop us a note to help
> > improve the system. BTW, we also suggest to use '--base' option to specify the
> > base tree in git format-patch, please see https://stackoverflow.com/a/37406982]
> >
> > url: https://github.com/0day-ci/linux/commits/Gal-Pressman/EFA-host-information/20200510-200519
> > base: https://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma.git for-next
> > config: riscv-allyesconfig (attached as .config)
> > compiler: riscv64-linux-gcc (GCC) 9.3.0
> > reproduce:
> > wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
> > chmod +x ~/bin/make.cross
> > # save the attached .config to linux build tree
> > COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=riscv
> >
> > If you fix the issue, kindly add following tag as appropriate
> > Reported-by: kbuild test robot <lkp@intel.com>
> >
> > All errors (new ones prefixed by >>):
> >
> > drivers/infiniband/hw/efa/efa_main.c: In function 'efa_set_host_info':
> >>> drivers/infiniband/hw/efa/efa_main.c:214:21: error: 'LINUX_VERSION_CODE' undeclared (first use in this function)
> > 214 | hinf->kernel_ver = LINUX_VERSION_CODE;
> > | ^~~~~~~~~~~~~~~~~~
> > drivers/infiniband/hw/efa/efa_main.c:214:21: note: each undeclared identifier is reported only once for each function it appears in
> >
> > vim +/LINUX_VERSION_CODE +214 drivers/infiniband/hw/efa/efa_main.c
> >
> > 190
> > 191 static void efa_set_host_info(struct efa_dev *dev)
> > 192 {
> > 193 struct efa_admin_set_feature_resp resp = {};
> > 194 struct efa_admin_set_feature_cmd cmd = {};
> > 195 struct efa_admin_host_info *hinf;
> > 196 u32 bufsz = sizeof(*hinf);
> > 197 dma_addr_t hinf_dma;
> > 198
> > 199 if (!efa_com_check_supported_feature_id(&dev->edev,
> > 200 EFA_ADMIN_HOST_INFO))
> > 201 return;
> > 202
> > 203 /* Failures in host info set shall not disturb probe */
> > 204 hinf = dma_alloc_coherent(&dev->pdev->dev, bufsz, &hinf_dma,
> > 205 GFP_KERNEL);
> > 206 if (!hinf)
> > 207 return;
> > 208
> > 209 strlcpy(hinf->os_dist_str, utsname()->release,
> > 210 min(sizeof(hinf->os_dist_str), sizeof(utsname()->release)));
> > 211 hinf->os_type = EFA_ADMIN_OS_LINUX;
> > 212 strlcpy(hinf->kernel_ver_str, utsname()->version,
> > 213 min(sizeof(hinf->kernel_ver_str), sizeof(utsname()->version)));
> > > 214 hinf->kernel_ver = LINUX_VERSION_CODE;
> > 215 EFA_SET(&hinf->bdf, EFA_ADMIN_HOST_INFO_BUS, dev->pdev->bus->number);
> > 216 EFA_SET(&hinf->bdf, EFA_ADMIN_HOST_INFO_DEVICE,
> > 217 PCI_SLOT(dev->pdev->devfn));
> > 218 EFA_SET(&hinf->bdf, EFA_ADMIN_HOST_INFO_FUNCTION,
> > 219 PCI_FUNC(dev->pdev->devfn));
> > 220 EFA_SET(&hinf->spec_ver, EFA_ADMIN_HOST_INFO_SPEC_MAJOR,
> > 221 EFA_COMMON_SPEC_VERSION_MAJOR);
> > 222 EFA_SET(&hinf->spec_ver, EFA_ADMIN_HOST_INFO_SPEC_MINOR,
> > 223 EFA_COMMON_SPEC_VERSION_MINOR);
> > 224 EFA_SET(&hinf->flags, EFA_ADMIN_HOST_INFO_INTREE, 1);
> > 225
> > 226 efa_com_set_feature_ex(&dev->edev, &resp, &cmd, EFA_ADMIN_HOST_INFO,
> > 227 hinf_dma, bufsz);
> > 228
> > 229 dma_free_coherent(&dev->pdev->dev, bufsz, hinf, hinf_dma);
> > 230 }
> > 231
> >
> > ---
> > 0-DAY CI Kernel Test Service, Intel Corporation
> > https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
> >
>
> Thanks robot, I'm missing an #include <linux/version.h> in efa_main.c.
I'm not so sure that you can use that header.
You need to use "#include <generated/utsrelease.h>" instead of
LINUX_VERSION.
Thanks
WARNING: multiple messages have this Message-ID (diff)
From: Leon Romanovsky <leon@kernel.org>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH for-next 2/2] RDMA/efa: Report host information to the device
Date: Sun, 10 May 2020 18:11:02 +0300 [thread overview]
Message-ID: <20200510151102.GC199306@unreal> (raw)
In-Reply-To: <2b98035f-aa55-1b11-7012-fddca885ba4f@amazon.com>
[-- Attachment #1: Type: text/plain, Size: 4127 bytes --]
On Sun, May 10, 2020 at 05:40:21PM +0300, Gal Pressman wrote:
> On 10/05/2020 16:42, kbuild test robot wrote:
> > Hi Gal,
> >
> > I love your patch! Yet something to improve:
> >
> > [auto build test ERROR on rdma/for-next]
> > [also build test ERROR on v5.7-rc4 next-20200508]
> > [if your patch is applied to the wrong git tree, please drop us a note to help
> > improve the system. BTW, we also suggest to use '--base' option to specify the
> > base tree in git format-patch, please see https://stackoverflow.com/a/37406982]
> >
> > url: https://github.com/0day-ci/linux/commits/Gal-Pressman/EFA-host-information/20200510-200519
> > base: https://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma.git for-next
> > config: riscv-allyesconfig (attached as .config)
> > compiler: riscv64-linux-gcc (GCC) 9.3.0
> > reproduce:
> > wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
> > chmod +x ~/bin/make.cross
> > # save the attached .config to linux build tree
> > COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=riscv
> >
> > If you fix the issue, kindly add following tag as appropriate
> > Reported-by: kbuild test robot <lkp@intel.com>
> >
> > All errors (new ones prefixed by >>):
> >
> > drivers/infiniband/hw/efa/efa_main.c: In function 'efa_set_host_info':
> >>> drivers/infiniband/hw/efa/efa_main.c:214:21: error: 'LINUX_VERSION_CODE' undeclared (first use in this function)
> > 214 | hinf->kernel_ver = LINUX_VERSION_CODE;
> > | ^~~~~~~~~~~~~~~~~~
> > drivers/infiniband/hw/efa/efa_main.c:214:21: note: each undeclared identifier is reported only once for each function it appears in
> >
> > vim +/LINUX_VERSION_CODE +214 drivers/infiniband/hw/efa/efa_main.c
> >
> > 190
> > 191 static void efa_set_host_info(struct efa_dev *dev)
> > 192 {
> > 193 struct efa_admin_set_feature_resp resp = {};
> > 194 struct efa_admin_set_feature_cmd cmd = {};
> > 195 struct efa_admin_host_info *hinf;
> > 196 u32 bufsz = sizeof(*hinf);
> > 197 dma_addr_t hinf_dma;
> > 198
> > 199 if (!efa_com_check_supported_feature_id(&dev->edev,
> > 200 EFA_ADMIN_HOST_INFO))
> > 201 return;
> > 202
> > 203 /* Failures in host info set shall not disturb probe */
> > 204 hinf = dma_alloc_coherent(&dev->pdev->dev, bufsz, &hinf_dma,
> > 205 GFP_KERNEL);
> > 206 if (!hinf)
> > 207 return;
> > 208
> > 209 strlcpy(hinf->os_dist_str, utsname()->release,
> > 210 min(sizeof(hinf->os_dist_str), sizeof(utsname()->release)));
> > 211 hinf->os_type = EFA_ADMIN_OS_LINUX;
> > 212 strlcpy(hinf->kernel_ver_str, utsname()->version,
> > 213 min(sizeof(hinf->kernel_ver_str), sizeof(utsname()->version)));
> > > 214 hinf->kernel_ver = LINUX_VERSION_CODE;
> > 215 EFA_SET(&hinf->bdf, EFA_ADMIN_HOST_INFO_BUS, dev->pdev->bus->number);
> > 216 EFA_SET(&hinf->bdf, EFA_ADMIN_HOST_INFO_DEVICE,
> > 217 PCI_SLOT(dev->pdev->devfn));
> > 218 EFA_SET(&hinf->bdf, EFA_ADMIN_HOST_INFO_FUNCTION,
> > 219 PCI_FUNC(dev->pdev->devfn));
> > 220 EFA_SET(&hinf->spec_ver, EFA_ADMIN_HOST_INFO_SPEC_MAJOR,
> > 221 EFA_COMMON_SPEC_VERSION_MAJOR);
> > 222 EFA_SET(&hinf->spec_ver, EFA_ADMIN_HOST_INFO_SPEC_MINOR,
> > 223 EFA_COMMON_SPEC_VERSION_MINOR);
> > 224 EFA_SET(&hinf->flags, EFA_ADMIN_HOST_INFO_INTREE, 1);
> > 225
> > 226 efa_com_set_feature_ex(&dev->edev, &resp, &cmd, EFA_ADMIN_HOST_INFO,
> > 227 hinf_dma, bufsz);
> > 228
> > 229 dma_free_coherent(&dev->pdev->dev, bufsz, hinf, hinf_dma);
> > 230 }
> > 231
> >
> > ---
> > 0-DAY CI Kernel Test Service, Intel Corporation
> > https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
> >
>
> Thanks robot, I'm missing an #include <linux/version.h> in efa_main.c.
I'm not so sure that you can use that header.
You need to use "#include <generated/utsrelease.h>" instead of
LINUX_VERSION.
Thanks
next prev parent reply other threads:[~2020-05-10 15:11 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-10 11:59 [PATCH for-next 0/2] EFA host information Gal Pressman
2020-05-10 11:59 ` [PATCH for-next 1/2] RDMA/efa: Fix setting of wrong bit in get/set_feature commands Gal Pressman
2020-05-10 11:59 ` [PATCH for-next 2/2] RDMA/efa: Report host information to the device Gal Pressman
2020-05-10 12:29 ` Leon Romanovsky
2020-05-10 13:05 ` Gal Pressman
2020-05-10 15:16 ` Leon Romanovsky
2020-05-11 12:47 ` Gal Pressman
2020-05-11 16:34 ` Leon Romanovsky
2020-05-10 13:42 ` kbuild test robot
2020-05-10 13:42 ` kbuild test robot
2020-05-10 14:40 ` Gal Pressman
2020-05-10 15:11 ` Leon Romanovsky [this message]
2020-05-10 15:11 ` Leon Romanovsky
2020-05-11 12:40 ` Gal Pressman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200510151102.GC199306@unreal \
--to=leon@kernel.org \
--cc=dledford@redhat.com \
--cc=firasj@amazon.com \
--cc=galpress@amazon.com \
--cc=gtzalik@amazon.com \
--cc=jgg@ziepe.ca \
--cc=kbuild-all@lists.01.org \
--cc=linux-rdma@vger.kernel.org \
--cc=lkp@intel.com \
--cc=matua@amazon.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.