/* calc_timing - calculate timing divisor value and check in range. @hwtm: The hardware timing in 10ths of nanoseconds. @clk_tns: The clock period in 10ths of nanoseconds. @err: Pointer to err variable to update in event of failure.  */
static unsigned int calc_timing(unsigned int hwtm, unsigned int clk_tns, unsigned int *err)
/* calc_timing - calculate timing divisor value and check in range. @hwtm: The hardware timing in 10ths of nanoseconds. @clk_tns: The clock period in 10ths of nanoseconds. @err: Pointer to err variable to update in event of failure.  */
static unsigned int calc_timing(unsigned int hwtm, unsigned int clk_tns, unsigned int *err)
{
	unsigned int ret = to_div(hwtm, clk_tns);
	if (ret > 0xf)
		*err = -EINVAL;
	return ret;
}