From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751316AbdJDHUX (ORCPT ); Wed, 4 Oct 2017 03:20:23 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:52684 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750945AbdJDHUW (ORCPT ); Wed, 4 Oct 2017 03:20:22 -0400 Date: Wed, 4 Oct 2017 09:20:30 +0200 From: Greg KH To: Pintu Agarwal Cc: linux-kernel@vger.kernel.org, labbott@redhat.com, pintu_agarwal@yahoo.com Subject: Re: [PATCHv2 1/1] [tools]: android/ion: userspace test utility for ion buffer sharing Message-ID: <20171004072030.GA11798@kroah.com> References: <1506449281-8790-1-git-send-email-pintu.ping@gmail.com> <1507049339-16963-1-git-send-email-pintu.ping@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1507049339-16963-1-git-send-email-pintu.ping@gmail.com> User-Agent: Mutt/1.9.1 (2017-09-22) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 03, 2017 at 12:48:59PM -0400, Pintu Agarwal wrote: > This is a test utility to verify ION buffer sharing in user space > between 2 independent processes. > It uses unix domain socket as IPC to transfer an FD to another process > and install it. > > This utility demonstrates how ION buffer sharing can be implemented between > two user space processes, using various heap ids. > > This utility is verified on Ubuntu 32-bit machine using 2 independent > process such as: ionapp_export (server) and ionapp_import (client). > First the server needs to be run to export FD to the client. > This utility works only if /dev/ion interface is present. > > Here is a sample demo example: > > linux/tools/android/ion$ sudo ./ionapp_export.out -i 1 -s 10 > heap_type: 2, heap_size: 10 > Fill buffer content: > 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd > Sharing fd: 6, Client fd: 5 > : buffer release successfully.... > > linux/tools/android/ion$ sudo ./ionapp_import.out > Received buffer fd: 4 > Read buffer content: > 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd > 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 > 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 > Fill buffer content: > 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd > 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd > 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd 0xfd > : buffer release successfully.... Can you tie this into the kselftest framework, to make automated tests of this kernel feature easier? thanks, greg k-h