From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53089) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y0YEf-0006dn-Po for qemu-devel@nongnu.org; Mon, 15 Dec 2014 11:11:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Y0YEZ-0005u1-Kz for qemu-devel@nongnu.org; Mon, 15 Dec 2014 11:11:01 -0500 Received: from mx1.redhat.com ([209.132.183.28]:51750) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y0YEZ-0005tx-Ct for qemu-devel@nongnu.org; Mon, 15 Dec 2014 11:10:55 -0500 Message-ID: <548F0806.80300@redhat.com> Date: Mon, 15 Dec 2014 17:10:46 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1418388243-1886-1-git-send-email-pbonzini@redhat.com> <1418388243-1886-5-git-send-email-pbonzini@redhat.com> <20141215160538.GJ5502@work-vm> In-Reply-To: <20141215160538.GJ5502@work-vm> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v3 4/4] serial: only resample THR interrupt on rising edge of IER.THRI List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Dr. David Alan Gilbert" Cc: imammedo@redhat.com, andrey@xdel.ru, qemu-devel@nongnu.org, batuzovk@ispras.ru On 15/12/2014 17:05, Dr. David Alan Gilbert wrote: > > + if ((changed & UART_IER_MSI) && s->poll_msl >= 0) { > > if (s->ier & UART_IER_MSI) { > > s->poll_msl = 1; > > serial_update_msl(s); > > This MSI stuff, this change is just intended to do the same as you're > doing for THRI and making it change based? The commit message and title > doens't mention it. It has no change. If MSI = 1, there is already a timer ticking every 100th of a second to poll the modem status, so it's useless to go through serial_udpate_msl/timer_del/... It's just because I have the changed bits at hand now. BTW, looks like the poll_msl subsection after all was not necessary. It can be gleaned by ANDing "does CHR_IOCTL_SERIAL_GET_TIOCM work?" (which is immutable state depending on the command-line configuration" with IER.MSI. Paolo