Content-Type: multipart/mixed; boundary="===============0244018982025914558==" MIME-Version: 1.0 From: Sean Young To: kbuild-all@lists.01.org Subject: Re: [PATCH v3] media: rc: pwm-ir-tx: Switch to atomic PWM API Date: Wed, 27 Oct 2021 08:32:04 +0100 Message-ID: <20211027073204.GA3978@gofer.mess.org> In-Reply-To: <20211027061552.bb4fczniqp6b7amh@pengutronix.de> List-Id: --===============0244018982025914558== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable On Wed, Oct 27, 2021 at 08:15:52AM +0200, Uwe Kleine-K=C3=B6nig wrote: > On Wed, Oct 27, 2021 at 02:07:19PM +0800, kernel test robot wrote: > > If you fix the issue, kindly add following tag as appropriate > > Reported-by: kernel test robot > > = > > All errors (new ones prefixed by >>, old ones prefixed by <<): > > = > > >> ERROR: modpost: "__udivdi3" [drivers/media/rc/pwm-ir-tx.ko] undefine= d! > = > This comes from the line: > = > state.duty_cycle =3D DIV_ROUND_CLOSEST(pwm_ir->duty_cycle * state.period= , 100); > = > where DIV_ROUND_CLOSEST expands to a normal division but state.period is > a u64. So this should use DIV64_U64_ROUND_CLOSEST I guess. DIV64_U64_ROUND_CLOSEST is for dividing a u64 with a u64. We're dividing by 100 here so this is not necessary. It should use DIV_ROUND_CLOSEST_ULL, however it might be nicer to use: pwm_set_relative_duty_cycle(&state, pwm_ir->duty_cycle, 100); Thanks Sean --===============0244018982025914558==--