On Fri, May 20, 2016 at 10:57:16AM +0800, Andy Duan wrote: > Did bind/unbind uart5 device on i.MX6SX platform like below command, there > have NULL pointer dereference cause kernel oops. > echo 21f4000.serial > /sys/bus/platform/drivers/imx-uart/bind > echo 21f4000.serial > /sys/bus/platform/drivers/imx-uart/unbind > > The driver does not define .release_port/.request_port for uart_ops, and > uart_remove_one_port() doesn't check if this op is NULL before calling it, > so add these interfaces to support bind/unbind operation. Why not fix the root of the problem, and have uart_remove_one_port check before calling? That way you fix all of the drivers, not just this one? thanks, greg k-h -- To unsubscribe from this list: send the line "unsubscribe linux-serial" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html