linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: William Breathitt Gray <vilhelm.gray@gmail.com>,
	jic23@kernel.org, fabrice.gasnier@foss.st.com
Cc: kbuild-all@lists.01.org, clang-built-linux@googlegroups.com,
	fabrice.gasnier@st.com, linux-kernel@vger.kernel.org,
	linux-iio@vger.kernel.org, benjamin.gaignard@st.com,
	William Breathitt Gray <vilhelm.gray@gmail.com>,
	Syed Nayyar Waris <syednwaris@gmail.com>
Subject: Re: [PATCH 1/2] counter: 104-quad-8: Remove IIO counter ABI
Date: Wed, 27 Jan 2021 18:10:54 +0800	[thread overview]
Message-ID: <202101271858.McyeRm4s-lkp@intel.com> (raw)
In-Reply-To: <40f5fd9eb590980e443a1b82689c5b4da059b720.1611473891.git.vilhelm.gray@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 4972 bytes --]

Hi William,

I love your patch! Yet something to improve:

[auto build test ERROR on iio/togreg]
[also build test ERROR on linux/master linus/master v5.11-rc5 next-20210125]
[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/William-Breathitt-Gray/Remove-the-IIO-counter-ABI/20210125-210945
base:   https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git togreg
config: x86_64-randconfig-a003-20210126 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 925ae8c790c7e354f12ec14a6cac6aa49fc75b29)
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/93b6ce4252570c170c0a65a5d2ba200a5cb07967
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review William-Breathitt-Gray/Remove-the-IIO-counter-ABI/20210125-210945
        git checkout 93b6ce4252570c170c0a65a5d2ba200a5cb07967
        # 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@intel.com>

All errors (new ones prefixed by >>):

>> drivers/counter/104-quad-8.c:1036:40: error: too few arguments to function call, expected 3, have 2
           priv = devm_kzalloc(dev, sizeof(*priv));
                  ~~~~~~~~~~~~                   ^
   include/linux/device.h:215:21: note: 'devm_kzalloc' declared here
   static inline void *devm_kzalloc(struct device *dev, size_t size, gfp_t gfp)
                       ^
   1 error generated.


vim +1036 drivers/counter/104-quad-8.c

  1022	
  1023	static int quad8_probe(struct device *dev, unsigned int id)
  1024	{
  1025		struct quad8 *priv;
  1026		int i, j;
  1027		unsigned int base_offset;
  1028		int err;
  1029	
  1030		if (!devm_request_region(dev, base[id], QUAD8_EXTENT, dev_name(dev))) {
  1031			dev_err(dev, "Unable to lock port addresses (0x%X-0x%X)\n",
  1032				base[id], base[id] + QUAD8_EXTENT);
  1033			return -EBUSY;
  1034		}
  1035	
> 1036		priv = devm_kzalloc(dev, sizeof(*priv));
  1037		if (!priv)
  1038			return -ENOMEM;
  1039	
  1040		/* Initialize Counter device and driver data */
  1041		priv->counter.name = dev_name(dev);
  1042		priv->counter.parent = dev;
  1043		priv->counter.ops = &quad8_ops;
  1044		priv->counter.counts = quad8_counts;
  1045		priv->counter.num_counts = ARRAY_SIZE(quad8_counts);
  1046		priv->counter.signals = quad8_signals;
  1047		priv->counter.num_signals = ARRAY_SIZE(quad8_signals);
  1048		priv->counter.priv = priv;
  1049		priv->base = base[id];
  1050	
  1051		/* Initialize mutex */
  1052		mutex_init(&priv->lock);
  1053	
  1054		/* Reset all counters and disable interrupt function */
  1055		outb(QUAD8_CHAN_OP_RESET_COUNTERS, base[id] + QUAD8_REG_CHAN_OP);
  1056		/* Set initial configuration for all counters */
  1057		for (i = 0; i < QUAD8_NUM_COUNTERS; i++) {
  1058			base_offset = base[id] + 2 * i;
  1059			/* Reset Byte Pointer */
  1060			outb(QUAD8_CTR_RLD | QUAD8_RLD_RESET_BP, base_offset + 1);
  1061			/* Reset filter clock factor */
  1062			outb(0, base_offset);
  1063			outb(QUAD8_CTR_RLD | QUAD8_RLD_RESET_BP | QUAD8_RLD_PRESET_PSC,
  1064			     base_offset + 1);
  1065			/* Reset Byte Pointer */
  1066			outb(QUAD8_CTR_RLD | QUAD8_RLD_RESET_BP, base_offset + 1);
  1067			/* Reset Preset Register */
  1068			for (j = 0; j < 3; j++)
  1069				outb(0x00, base_offset);
  1070			/* Reset Borrow, Carry, Compare, and Sign flags */
  1071			outb(QUAD8_CTR_RLD | QUAD8_RLD_RESET_FLAGS, base_offset + 1);
  1072			/* Reset Error flag */
  1073			outb(QUAD8_CTR_RLD | QUAD8_RLD_RESET_E, base_offset + 1);
  1074			/* Binary encoding; Normal count; non-quadrature mode */
  1075			outb(QUAD8_CTR_CMR, base_offset + 1);
  1076			/* Disable A and B inputs; preset on index; FLG1 as Carry */
  1077			outb(QUAD8_CTR_IOR, base_offset + 1);
  1078			/* Disable index function; negative index polarity */
  1079			outb(QUAD8_CTR_IDR, base_offset + 1);
  1080		}
  1081		/* Disable Differential Encoder Cable Status for all channels */
  1082		outb(0xFF, base[id] + QUAD8_DIFF_ENCODER_CABLE_STATUS);
  1083		/* Enable all counters */
  1084		outb(QUAD8_CHAN_OP_ENABLE_COUNTERS, base[id] + QUAD8_REG_CHAN_OP);
  1085	
  1086		/* Register Counter device */
  1087		return devm_counter_register(dev, &priv->counter);
  1088	}
  1089	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 41846 bytes --]

  reply	other threads:[~2021-01-27 10:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-24  7:42 [PATCH 0/2] Remove the IIO counter ABI William Breathitt Gray
2021-01-24  7:42 ` [PATCH 1/2] counter: 104-quad-8: Remove " William Breathitt Gray
2021-01-27 10:10   ` kernel test robot [this message]
2021-01-24  7:42 ` [PATCH 2/2] iio: Remove the IIO counter ABI documentation William Breathitt Gray
2021-01-24 14:57 ` [PATCH 0/2] Remove the IIO counter ABI Jonathan Cameron

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=202101271858.McyeRm4s-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=benjamin.gaignard@st.com \
    --cc=clang-built-linux@googlegroups.com \
    --cc=fabrice.gasnier@foss.st.com \
    --cc=fabrice.gasnier@st.com \
    --cc=jic23@kernel.org \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=syednwaris@gmail.com \
    --cc=vilhelm.gray@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).