All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Raag Jadav <raag.jadav@intel.com>,
	jani.nikula@linux.intel.com, joonas.lahtinen@linux.intel.com,
	rodrigo.vivi@intel.com, tursulin@ursulin.net, airlied@gmail.com,
	daniel@ffwll.ch, linux@roeck-us.net, andi.shyti@linux.intel.com,
	andriy.shevchenko@linux.intel.com
Cc: oe-kbuild-all@lists.linux.dev, intel-gfx@lists.freedesktop.org,
	dri-devel@lists.freedesktop.org, linux-hwmon@vger.kernel.org,
	linux-kernel@vger.kernel.org, anshuman.gupta@intel.com,
	badal.nilawar@intel.com, riana.tauro@intel.com,
	ashutosh.dixit@intel.com, karthik.poosa@intel.com,
	Raag Jadav <raag.jadav@intel.com>
Subject: Re: [PATCH v5] drm/i915/hwmon: expose fan speed
Date: Tue, 13 Aug 2024 05:36:18 +0800	[thread overview]
Message-ID: <202408130500.SgCVoR2D-lkp@intel.com> (raw)
In-Reply-To: <20240812081538.1457396-1-raag.jadav@intel.com>

Hi Raag,

kernel test robot noticed the following build errors:

[auto build test ERROR on groeck-staging/hwmon-next]
[also build test ERROR on linus/master v6.11-rc3 next-20240812]
[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#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Raag-Jadav/drm-i915-hwmon-expose-fan-speed/20240812-161645
base:   https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git hwmon-next
patch link:    https://lore.kernel.org/r/20240812081538.1457396-1-raag.jadav%40intel.com
patch subject: [PATCH v5] drm/i915/hwmon: expose fan speed
config: i386-randconfig-012-20240813 (https://download.01.org/0day-ci/archive/20240813/202408130500.SgCVoR2D-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240813/202408130500.SgCVoR2D-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202408130500.SgCVoR2D-lkp@intel.com/

All errors (new ones prefixed by >>):

   ld: drivers/gpu/drm/i915/i915_hwmon.o: in function `hwm_fan_read':
>> drivers/gpu/drm/i915/i915_hwmon.c:675: undefined reference to `__udivdi3'


vim +675 drivers/gpu/drm/i915/i915_hwmon.c

   633	
   634	static int
   635	hwm_fan_read(struct hwm_drvdata *ddat, u32 attr, long *val)
   636	{
   637		struct i915_hwmon *hwmon = ddat->hwmon;
   638		struct hwm_fan_info *fi = &ddat->fi;
   639		u64 rotations, time_now, time;
   640		intel_wakeref_t wakeref;
   641		u32 reg_val, pulses;
   642		int ret = 0;
   643	
   644		if (attr != hwmon_fan_input)
   645			return -EOPNOTSUPP;
   646	
   647		wakeref = intel_runtime_pm_get(ddat->uncore->rpm);
   648		mutex_lock(&hwmon->hwmon_lock);
   649	
   650		reg_val = intel_uncore_read(ddat->uncore, hwmon->rg.fan_speed);
   651		time_now = get_jiffies_64();
   652	
   653		/* Handle HW register overflow */
   654		if (reg_val >= fi->reg_val_prev)
   655			pulses = reg_val - fi->reg_val_prev;
   656		else
   657			pulses = UINT_MAX - fi->reg_val_prev + reg_val;
   658	
   659		/*
   660		 * HW register value is accumulated count of pulses from
   661		 * PWM fan with the scale of 2 pulses per rotation.
   662		 */
   663		rotations = pulses / 2;
   664	
   665		time = jiffies_delta_to_msecs(time_now - fi->time_prev);
   666		if (unlikely(!time)) {
   667			ret = -EAGAIN;
   668			goto exit;
   669		}
   670	
   671		/*
   672		 * Convert to minutes for calculating RPM.
   673		 * RPM = number of rotations * msecs per minute / time in msecs
   674		 */
 > 675		*val = DIV_ROUND_UP(rotations * (MSEC_PER_SEC * 60), time);
   676	
   677		fi->reg_val_prev = reg_val;
   678		fi->time_prev = time_now;
   679	exit:
   680		mutex_unlock(&hwmon->hwmon_lock);
   681		intel_runtime_pm_put(ddat->uncore->rpm, wakeref);
   682		return ret;
   683	}
   684	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

  parent reply	other threads:[~2024-08-12 21:36 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-12  8:15 [PATCH v5] drm/i915/hwmon: expose fan speed Raag Jadav
2024-08-12 10:14 ` ✓ Fi.CI.BAT: success for drm/i915/hwmon: expose fan speed (rev5) Patchwork
2024-08-12 13:15 ` [PATCH v5] drm/i915/hwmon: expose fan speed Andy Shevchenko
2024-08-13  5:45   ` Raag Jadav
2024-08-13  8:27     ` Andy Shevchenko
2024-08-13 10:03       ` Raag Jadav
2024-08-12 13:50 ` Andi Shyti
2024-08-13  6:30   ` Raag Jadav
2024-08-21 14:58     ` Andi Shyti
2024-08-12 21:36 ` kernel test robot [this message]
2024-08-12 22:43 ` ✓ Fi.CI.IGT: success for drm/i915/hwmon: expose fan speed (rev5) Patchwork
2024-08-13  0:38 ` [PATCH v5] drm/i915/hwmon: expose fan speed kernel test robot

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=202408130500.SgCVoR2D-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=airlied@gmail.com \
    --cc=andi.shyti@linux.intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=anshuman.gupta@intel.com \
    --cc=ashutosh.dixit@intel.com \
    --cc=badal.nilawar@intel.com \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@linux.intel.com \
    --cc=joonas.lahtinen@linux.intel.com \
    --cc=karthik.poosa@intel.com \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=raag.jadav@intel.com \
    --cc=riana.tauro@intel.com \
    --cc=rodrigo.vivi@intel.com \
    --cc=tursulin@ursulin.net \
    /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.