> + ret = kstrtoull(buf, base, &val); > + if (!ret) > + *result = val;
Simply pass "result" directly to kstrtoull(). It will not write the result in case of error.
> + ret = kstrtoull(buf, base, &val); > + if (!ret) > + *result = val;
Simply pass "result" directly to kstrtoull(). It will not write the result in case of error.