From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754983AbbB0U10 (ORCPT ); Fri, 27 Feb 2015 15:27:26 -0500 Received: from mx1.redhat.com ([209.132.183.28]:39579 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753122AbbB0U1Z (ORCPT ); Fri, 27 Feb 2015 15:27:25 -0500 Date: Fri, 27 Feb 2015 21:27:15 +0100 From: Radim =?utf-8?B?S3LEjW3DocWZ?= To: Vitaly Kuznetsov Cc: "K. Y. Srinivasan" , devel@linuxdriverproject.org, Haiyang Zhang , linux-kernel@vger.kernel.org, Dexuan Cui , Greg Kroah-Hartman , linux-api@vger.kernel.org Subject: Re: [PATCH RFC 1/3] Drivers: hv: kvp: convert userspace/kernel communication to using char device Message-ID: <20150227202715.GF2034@potion.brq.redhat.com> References: <1425053665-635-1-git-send-email-vkuznets@redhat.com> <1425053665-635-2-git-send-email-vkuznets@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1425053665-635-2-git-send-email-vkuznets@redhat.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 2015-02-27 17:14+0100, Vitaly Kuznetsov: > Re-implement the communication using misc char device. Use ioctl to do > kernel/userspace version negotiation (doesn't make much sense at this moment > as we're breaking backwards compatibility but can be used in future). The main question is whether we want to abolish backward compatibility; kernel rules are usually against breakages and it's hard to prove that the bundled daemon is a sole user and gets updated at the same time. (Note: I'd gladly break anything.) The ioctl is used too creatively for my liking: as an out-of-band communication that is required after the main channel has been opened. It would be simpler to inject the version into first x bytes of the stream, making a read() after open() mandatory. (I've only done a high level overview so far.)