LKML Archive on
help / color / mirror / Atom feed
From: David Daney <>
To: Alan Cox <>
Cc: Andrew Morton <>,,,,
Subject: Re: [PATCH] serial: Initialize spinlocks in 8250 and don't clobber them.
Date: Tue, 21 Oct 2008 08:35:39 -0700	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

Alan Cox wrote:
>> But yes, copying a spinlock by value is quite wrong.  Perhaps we could
>> retain the struct assigment and then run spin_lock_init() to get the
>> spinlock into a sane state?
> Kind of irrelevant now however, the split of patches that caused the
> original bug is over and the NR_IRQ removal patch half of it hit Linus
> tree.
My original patch fixed *two* problems.  As you note here, you already fixed the first one.

As far as I know, the second problem is still present, and that is what akpm was referring to above.  Several days ago I posted a revised patch for this here:

The question is:  What is the best way to initialize some (or all) fields of a structure *except* a single lock field that was previously initialized?

We can just copy field by field as my patch does, or you could do something ugly using memcpy on portions of the structure.  In this case we know which structure elements will be used by the early console, so I just copied them.

Any comments about that patch are certainly most welcome.

David Daney

  reply	other threads:[~2008-10-21 15:36 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-14 21:37 David Daney
2008-10-20 21:17 ` Andrew Morton
2008-10-20 21:37   ` David Daney
2008-10-21  9:38   ` Alan Cox
2008-10-21 15:35     ` David Daney [this message]
2008-10-21 15:50       ` Alan Cox

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:

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

  git send-email \ \ \ \ \ \ \ \ \
    --subject='Re: [PATCH] serial: Initialize spinlocks in 8250 and don'\''t clobber them.' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).