qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Alex Bennée" <alex.bennee@linaro.org>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH v2 1/1] integrator: fix Linux boot failure by emulating dbg
Date: Tue, 15 Oct 2013 15:25:01 +0100	[thread overview]
Message-ID: <p1siw2r4qq.fsf@linaro.org> (raw)
In-Reply-To: <CAFEAcA_8Hxsju-VJshC1ZnXWrPAA4RuPTL-duJ0FYySSjbjbng@mail.gmail.com>


peter.maydell@linaro.org writes:

> On 16 September 2013 13:50,  <alex.bennee@linaro.org> wrote:
>> From: Alex Bennée <alex@bennee.com>
>>
>> Commit 9b8c69243 broke the ability to boot the kernel as the value
>> returned by unassigned_mem_read returned non-zero and left the kernel
>> looping forever waiting for it to change (see integrator_led_set in
>> the kernel code).
>
> This generally looks OK, but I have a few nits.

OK

>> Relying on a varying implementation detail is incorrect anyway so this
>> introduces a memory region to emulate the debug/led region on the
>> integrator board. It is currently a basic stub as I have no idea what the
>> behaviour of this region should be so for now it simply returns 0's as
>> the old unassigned_mem_read did.
>
> It looks like you need to update the commit message -- you
> looked at the board docs, so we do know the correct behaviour.

True, I shall update.

>> +++ b/hw/misc/arm_intdbg.c
>> @@ -0,0 +1,90 @@
>> +/*
>> + * LED, Switch and Debug control registers for ARM Integrator Boards
>> + *
>> + * This currently is a stub for this functionality written with
>> + * reference to what the Linux kernel looks at. Previously we relied
>> + * on the behaviour of unassigned_mem_read() in the core.
>
> This sounds like the code was written based on the kernel, not
> on the board docs, which is wrong, so I think it could use
> rephrasing. There's no need to mention previous behaviour either
> IMHO -- people who care can look at the commit history.

Sure. I've got a bunch of other review comments to address so I can
clean this up. Unfortunately I've been so busy with other stuff I
haven't had a chance to go through them yet.

As it happens it looks like the integrator image is now running again on
the current HEAD which has made this a little less urgent. However it
does raise an interesting question as to why!

>> + *
>> + * The real h/w is described at:
>> + *  http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0159b/Babbfijf.html
>> + *
>> + * Written by Alex Bennée
>
> Assuming you wrote this with your Linaro hat on, the comment
> should have a
>  * Copyright (c) 2013 Linaro Limited
>
> in it above your 'Written by' line.

Yeah, I was holding off that until I was officially on the clock
although as noticed I have been taking advantage of the email facilities
as a handy place to have the mailing list go through.

<snip>
>> +        /* Nothing interesting implemented yet.  */
>> +        qemu_log_mask(LOG_UNIMP, "dbg_control_write: ignoring write of %lx to %x:%d\n", value, (int)offset, size);
>> +        break;
>> +    default:
>> +        qemu_log_mask(LOG_GUEST_ERROR, "dbg_control_write: write of %lx to bad offset %x\n", value, (int)offset);
>
> This looks like an overlength line : checkpatch.pl should
> warn if so. (I think there are others too.)

OK thanks.

-- 
Alex Bennée

  reply	other threads:[~2013-10-15 14:25 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-13 14:58 [Qemu-devel] [PATCH] integrator: fix Linux boot failure by emulating dbg alex.bennee
2013-09-13 15:20 ` Peter Maydell
2013-09-13 17:39   ` Peter Maydell
2013-09-16 12:50   ` [Qemu-devel] [PATCH v2 0/0] " alex.bennee
2013-09-16 12:50     ` [Qemu-devel] [PATCH v2 1/1] " alex.bennee
2013-10-15 13:21       ` Peter Maydell
2013-10-15 14:25         ` Alex Bennée [this message]
2013-10-15 14:30           ` Peter Maydell
  -- strict thread matches above, loose matches on Subject: below --
2013-09-18 14:28 alex.bennee
2013-09-18 14:31 [Qemu-devel] [PATCH v2 0/0] " alex.bennee
2013-09-18 14:31 ` [Qemu-devel] [PATCH v2 1/1] " alex.bennee
2013-09-18 15:54   ` Andreas Färber
2013-09-18 16:06     ` Alex Bennée

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=p1siw2r4qq.fsf@linaro.org \
    --to=alex.bennee@linaro.org \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.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;
as well as URLs for NNTP newsgroup(s).