mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Américo Wang" <xiyou.wangcong@gmail.com>
To: Jan Engelhardt <jengelh@medozas.de>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	jdike@addtoit.com
Subject: Re: uml: using hostfs as rootfs is not working
Date: Fri, 21 Nov 2008 17:44:26 +0000	[thread overview]
Message-ID: <20081121174426.GB23653@hack.voiplan.pt> (raw)
In-Reply-To: <alpine.LNX.1.10.0811191930090.4486@fbirervta.pbzchgretzou.qr>

On Wed, Nov 19, 2008 at 07:32:16PM +0100, Jan Engelhardt wrote:
>Hi,
>

Hi, Jan!


>
>as per Documentation/uml/*txt, I issued the following to get a direct 
>hostfs:
>
>	./linux ubd0=/tftpboot/linux
>
>(/tftpboot/linux/sbin/init exists), but the UM kernel only gives:
>
>Failed to open '/home/tftpboot/linux', errno = 21


I think this error comes from arch/um/drivers/ubd_kern.c::ubd_open_dev()


>ubda: Can't open "/home/tftpboot/linux": errno = 21

This is from the caller: ubd_open().

ubd_open_dev() calls open_ubd_file() to open the ubd device, which, in
turn, calls os_open_file() which is a wrapper of open64().

And errno 21 should be EISDIR, for open(), which means we invoked it
with a writing operation, probably O_RDWR...

So I think there must be something wrong in the code, writing to a
directory is suspicious...

I will try to check it.

Thank you!

-- 
"Sometimes the only way to stay sane is to go a little crazy."


      reply	other threads:[~2008-11-21 17:44 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-19 18:32 Jan Engelhardt
2008-11-21 17:44 ` Américo Wang [this message]

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=20081121174426.GB23653@hack.voiplan.pt \
    --to=xiyou.wangcong@gmail.com \
    --cc=jdike@addtoit.com \
    --cc=jengelh@medozas.de \
    --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®