All of lore.kernel.org
 help / color / mirror / Atom feed
From: Darren Hart <dvhart@linux.intel.com>
To: Pekka Enberg <penberg@cs.helsinki.fi>
Cc: Sasha Levin <levinsasha928@gmail.com>,
	kvm@vger.kernel.org, mingo@elte.hu, asias.hejun@gmail.com,
	gorcunov@gmail.com
Subject: Re: [PATCH 1/2] kvm tools: Add missing 9p remove handler
Date: Mon, 07 Nov 2011 12:52:36 -0800	[thread overview]
Message-ID: <4EB84514.2060008@linux.intel.com> (raw)
In-Reply-To: <1320680298.1428.89.camel@jaguar>

Hi Pekka,

On 11/07/2011 07:38 AM, Pekka Enberg wrote:
> On Mon, 2011-11-07 at 17:19 +0200, Sasha Levin wrote:
>> Signed-off-by: Sasha Levin <levinsasha928@gmail.com>
> 
> -ENOCHANGELOG :-)
> 
> I assume this is related to the git problems Darren Hart reported on
> Google Plus?

These patches certainly help things along. The git init command now
completes and and I can remove existing git repositories (which I could
not before).

I was unable to get a git clone to complete (hangs at receiving objects
0%). I was able to create a new repository, edit a file, add it, and
commit it. "git log" return nothing, same with git show HEAD:

sh-4.2# cd 9ptest/
sh-4.2# ls
world
sh-4.2# git status
# On branch master
nothing to commit (working directory clean)

(so it doesn't list "world" as untracked nor as changed but not
committed). It has been committed.

sh-4.2# git log
sh-4.2# git show HEAD
sh-4.2# git whatchanged HEAD

A couple nitpics below:

> 
>> ---
>>  tools/kvm/virtio/9p.c |   25 +++++++++++++++++++++++++
>>  1 files changed, 25 insertions(+), 0 deletions(-)
>>
>> diff --git a/tools/kvm/virtio/9p.c b/tools/kvm/virtio/9p.c
>> index 1569bb2..08b1be7 100644
>> --- a/tools/kvm/virtio/9p.c
>> +++ b/tools/kvm/virtio/9p.c
>> @@ -677,6 +677,30 @@ err_out:
>>  	return;
>>  }
>>  
>> +static void virtio_p9_remove(struct p9_dev *p9dev,
>> +			       struct p9_pdu *pdu, u32 *outlen)
>> +{
>> +	int ret;
>> +	u32 fid_val;
>> +	struct p9_fid *fid;
>> +	char full_path[PATH_MAX];
>> +
>> +	virtio_p9_pdu_readf(pdu, "d", &fid_val);
>> +	fid = &p9dev->fids[fid_val];
>> +
>> +	sprintf(full_path, "%s", fid->abs_path);
>> +	ret = remove(full_path);
>> +	if (ret < 0)
>> +		goto err_out;
>> +	*outlen = pdu->write_offset;
>> +	virtio_p9_set_reply_header(pdu, *outlen);
>> +	return;
>> +
>> +err_out:
>> +	virtio_p9_error_reply(p9dev, pdu, errno, outlen);
>> +	return;	

EOL whitespace ^


The same issue exists with the _rename patch following this one.

>> +}
>> +			       

EOL white space ^

>>  static void virtio_p9_readlink(struct p9_dev *p9dev,
>>  			       struct p9_pdu *pdu, u32 *outlen)
>>  {
>> @@ -1048,6 +1072,7 @@ static p9_handler *virtio_9p_dotl_handler [] = {
>>  	[P9_TSYMLINK]     = virtio_p9_symlink,
>>  	[P9_TLCREATE]     = virtio_p9_create,
>>  	[P9_TWRITE]       = virtio_p9_write,
>> +	[P9_TREMOVE]      = virtio_p9_remove,
>>  };
>>  
>>  static struct p9_pdu *virtio_p9_pdu_init(struct kvm *kvm, struct virt_queue *vq)
> 
> 

-- 
Darren Hart
Intel Open Source Technology Center
Yocto Project - Linux Kernel

  parent reply	other threads:[~2011-11-07 20:52 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-07 15:19 [PATCH 1/2] kvm tools: Add missing 9p remove handler Sasha Levin
2011-11-07 15:19 ` [PATCH 2/2] kvm tools: Add missing 9p rename handler Sasha Levin
2011-11-07 15:38 ` [PATCH 1/2] kvm tools: Add missing 9p remove handler Pekka Enberg
2011-11-07 15:38   ` Sasha Levin
2011-11-07 15:43     ` Pekka Enberg
2011-11-07 15:45       ` Sasha Levin
2011-11-07 20:52   ` Darren Hart [this message]
2011-11-07 21:40     ` Sasha Levin
2011-11-07 22:16       ` Darren Hart
2011-11-08  6:36         ` Pekka Enberg

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=4EB84514.2060008@linux.intel.com \
    --to=dvhart@linux.intel.com \
    --cc=asias.hejun@gmail.com \
    --cc=gorcunov@gmail.com \
    --cc=kvm@vger.kernel.org \
    --cc=levinsasha928@gmail.com \
    --cc=mingo@elte.hu \
    --cc=penberg@cs.helsinki.fi \
    /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.