From: "Ville Syrjälä" <syrjala@sci.fi>
To: Takashi Iwai <tiwai@suse.de>
Cc: alsa-devel <alsa-devel@lists.sourceforge.net>,
James Courtier-Dutton <James@superbug.co.uk>
Subject: Re: [alsa-cvslog] alsa-kernel: emu10k1: Fix outl() in snd_emu10k1_resume_regs()
Date: Wed, 4 Oct 2006 20:33:22 +0300 [thread overview]
Message-ID: <20061004173322.GA269@sci.fi> (raw)
In-Reply-To: <s5hfye4jbdb.wl%tiwai@suse.de>
On Wed, Oct 04, 2006 at 06:26:24PM +0200, Takashi Iwai wrote:
> At Wed, 04 Oct 2006 17:23:14 +0100,
> James Courtier-Dutton wrote:
> >
> > Takashi Iwai wrote:
> > > - outl(emu->port + A_IOCFG, emu->saved_a_iocfg);
> > > - outl(emu->port + HCFG, emu->saved_hcfg);
> > > + outl(emu->saved_a_iocfg, emu->port + A_IOCFG);
> > > + outl(emu->saved_hcfg, emu->port + HCFG);
> > >
> > Is there any tool to find out who got this wrong in the first place?
>
> One could check whether the argument is long or not. The long is
> likely an i/o port while the data is int or unsigned int.
> But, C allows implicit conversion, so the compiler would never
> complain...
Using sparse should help in avoiding this kind of bug.
--
Ville Syrjälä
syrjala@sci.fi
http://www.sci.fi/~syrjala/
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
next prev parent reply other threads:[~2006-10-04 17:33 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <ALOGGER1159978767.86@alsa-project.org>
2006-10-04 16:23 ` [alsa-cvslog] alsa-kernel: emu10k1: Fix outl() in snd_emu10k1_resume_regs() James Courtier-Dutton
2006-10-04 16:26 ` Takashi Iwai
2006-10-04 16:52 ` Takashi Iwai
2006-10-04 17:33 ` Ville Syrjälä [this message]
2006-10-04 16:36 ` Arnaud Patard
2006-10-04 16:43 ` James Courtier-Dutton
2006-10-04 16:52 ` Jochen Voss
2006-10-04 18:08 ` Jaroslav Kysela
2006-10-04 18:12 ` Jaroslav Kysela
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=20061004173322.GA269@sci.fi \
--to=syrjala@sci.fi \
--cc=James@superbug.co.uk \
--cc=alsa-devel@lists.sourceforge.net \
--cc=tiwai@suse.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.