From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935144AbdCLRyL (ORCPT ); Sun, 12 Mar 2017 13:54:11 -0400 Received: from mail-lf0-f44.google.com ([209.85.215.44]:34011 "EHLO mail-lf0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S935061AbdCLRyC (ORCPT ); Sun, 12 Mar 2017 13:54:02 -0400 Subject: Re: [PATCH 1/3] ata: add Palmchip BK3710 PATA controller driver To: Bartlomiej Zolnierkiewicz , Tejun Heo References: <1489064496-6270-1-git-send-email-b.zolnierkie@samsung.com> <1489064496-6270-2-git-send-email-b.zolnierkie@samsung.com> Cc: Sekhar Nori , Kevin Hilman , Arnd Bergmann , Russell King , Dmitry Eremin-Solenikov , linux-ide@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org From: Sergei Shtylyov Organization: Cogent Embedded Message-ID: <5aa862b6-d029-bbb5-c5a2-a1c9f87e7f0b@cogentembedded.com> Date: Sun, 12 Mar 2017 20:53:57 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 03/12/2017 08:28 PM, Sergei Shtylyov wrote: >> +static void pata_bk3710_set_piomode(struct ata_port *ap, >> + struct ata_device *adev) >> +{ >> + void __iomem *base = (void __iomem *)ap->ioaddr.bmdma_addr; >> + struct ata_device *pair = ata_dev_pair(adev); >> + const struct ata_timing *t = ata_timing_find_mode(adev->pio_mode); >> + const u16 *id = adev->id; >> + unsigned int cycle_time; >> + int is_slave = adev->devno; >> + const u8 pio = adev->pio_mode - XFER_PIO_0; >> + >> + if (id[ATA_ID_FIELD_VALID] & 2) { >> + if (ata_id_has_iordy(id)) >> + cycle_time = id[ATA_ID_EIDE_PIO_IORDY]; >> + else >> + cycle_time = id[ATA_ID_EIDE_PIO]; >> + >> + /* conservative "downgrade" for all pre-ATA2 drives */ >> + if (pio < 3 && cycle_time < t->cycle) >> + cycle_time = 0; /* use standard timing */ >> + } >> + >> + if (!cycle_time) >> + cycle_time = t->cycle; > > This seems like a helper needed by libata in general but OK... No, the build bot had already reported the problem with 'cycle_time' here, I just forgot about it. [...] > > Well, no serious issues found, so you can stamp: > > Acked-by: Sergei Shtylyov Too early, it seems... :-) MBR, Sergei