From addaebccf63a8c9f7c7a62ce1ceb9da4307c5a1c Mon Sep 17 00:00:00 2001 From: Peter Hurley Date: Sat, 15 Jun 2013 10:04:22 -0400 Subject: [PATCH] n_tty: Use separate head and tail indices for echo_buf Instead of using a single index to track the current echo_buf position, use a head index when adding to the buffer and a tail index when consuming from the buffer. Allow these head and tail indices to wrap at max representable value; perform modulo reduction via helper functions when accessing the buffer. Signed-off-by: Peter Hurley Signed-off-by: Greg Kroah-Hartman --- Reading git-format-patch failed