mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Alan Cox <alan@lxorguk.ukuu.org.uk>
To: Jeff Garzik <jeff@garzik.org>
Cc: akpm@osdl.org, linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] pata_cmd640: CMD640 PCI support
Date: Sat, 3 Mar 2007 00:52:19 +0000	[thread overview]
Message-ID: <20070303005219.3d870c84@lxorguk.ukuu.org.uk> (raw)
In-Reply-To: <45E8B28D.7030500@garzik.org>

> > +	if (ap->port_no != 0 && adev->devno != timing->last) {
> > +		pci_write_config_byte(pdev, DRWTIM23, timing->reg58[adev->devno]);
> > +		timing->last = adev->devno;
> > +	}
> 
> It might be worth looking into whether ->dev_select is a better place 
> for this sort of code

It isn't, for any driver because ->dev_select() is used extremely early
before all the setup of modes is even begun. This is why all the PATA
drivers hook qc_issue_prot instead.

> > +	static struct ata_port_info *port_info[2] = { &info, &info };
> > +
> > +	/* CMD640 detected, commiserations */
> > +	pci_write_config_byte(pdev, 0x5C, 0x00);
> 
> magic number

Indeed. Its undocumented magic.

> > +static int cmd640_reinit_one(struct pci_dev *pdev)
> > +{
> > +	return ata_pci_device_resume(pdev);
> > +}
> 
> appears to be useless wrapper

To remind me to add the resume path, which I've now done. Basically the
FIFO fixes go away on a resume ...

Alan

  reply	other threads:[~2007-03-02 23:48 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-02 15:03 Alan Cox
2007-03-02 23:26 ` Jeff Garzik
2007-03-03  0:52   ` Alan Cox [this message]
2007-03-03 17:12   ` Sergei Shtylyov
2007-03-03 20:33     ` Alan Cox
2007-03-03 19:38       ` Sergei Shtylyov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070303005219.3d870c84@lxorguk.ukuu.org.uk \
    --to=alan@lxorguk.ukuu.org.uk \
    --cc=akpm@osdl.org \
    --cc=jeff@garzik.org \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®