Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753080AbdLDV1w (ORCPT ); Mon, 4 Dec 2017 16:27:52 -0500 Received: from mail-eopbgr30126.outbound.protection.outlook.com ([40.107.3.126]:10076 "EHLO EUR03-AM5-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752954AbdLDV1t (ORCPT ); Mon, 4 Dec 2017 16:27:49 -0500 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=ktkhai@virtuozzo.com; Subject: Re: [PATCH 0/5] blkcg: Limit maximum number of aio requests available for cgroup To: Benjamin LaHaise Cc: axboe@kernel.dk, viro@zeniv.linux.org.uk, tj@kernel.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-aio@kvack.org, oleg@redhat.com References: <151240305010.10164.15584502480037205018.stgit@localhost.localdomain> <20171204165213.GF11494@kvack.org> From: Kirill Tkhai Message-ID: <08b9cab6-5237-c027-3bf3-08a69de7fe41@virtuozzo.com> Date: Tue, 5 Dec 2017 00:27:37 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: <20171204165213.GF11494@kvack.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [89.178.229.144] X-ClientProxiedBy: DB6PR0202CA0008.eurprd02.prod.outlook.com (2603:10a6:4:29::18) To VI1PR0801MB1343.eurprd08.prod.outlook.com (2603:10a6:800:3b::7) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 902f8c23-0c49-47cc-0f8a-08d53b5ddcdc X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(5600026)(4604075)(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(2017052603286);SRVR:VI1PR0801MB1343; X-Microsoft-Exchange-Diagnostics: 1;VI1PR0801MB1343;3:/Pyi8CZaoMn9C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v47FoFD3rs+mwxSX07+bdQ75N6kZIfw1tcBQl4oPWAU3rlHsglA/ewzPA/znepwyQCrCPCAtGoifoN7d8UsJ5bRMk8qrpMqi621xpnJbHPuQkL7uO4b0+jRvMpJaxmqYEJY3ZJf8A7Q55nFnnLg/OkHPyUY0OKHDvy2qyH7cbqaUts8Xs+keXVz2mE8Z5wF+5XVGLMx4nnZyIscUSALkHMFAZuXe0Tu/12WpWbSXfVe23XLcPc42REn5xTmFnI72djhsDqo=;4:woCxYytfptb5o5tD705ItVpyj1H3aMyj6sya9vMWzfpmkapvT3Ch/K7TEuiWZ80LzLj/Vp6BDUIrXeNoQz3lBifOJDYFLWbNBH8sKDn6lBl2tPO6EwYqqdzrt7oN/3J/1IMFOTeC4SERjlG99akhqw755CZgi3QqJhOqrKMB9EZRGBJa/O0vSUIIMhycPE3hY/IwtxkL5/F0qOntUCsHvw3xmhI5nx0dCqXzQqqDTCTjRc+7CXFuAqibQjdBNJTGt1U/6hTRc2mp0tHLNAhOpQ== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040450)(2401047)(5005006)(8121501046)(3002001)(10201501046)(3231022)(93006095)(93001095)(6041248)(20161123564025)(20161123558100)(20161123555025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(20161123560025)(6072148)(201708071742011);SRVR:VI1PR0801MB1343;BCL:0;PCL:0;RULEID:(100000803101)(100110400095);SRVR:VI1PR0801MB1343; X-Forefront-PRVS: 051158ECBB X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(6069001)(6009001)(346002)(366004)(376002)(189002)(24454002)(199003)(230700001)(3846002)(6116002)(305945005)(5660300001)(8676002)(81166006)(7736002)(81156014)(65826007)(2950100002)(53936002)(6666003)(6916009)(6512007)(189998001)(31686004)(36756003)(101416001)(229853002)(478600001)(8936002)(25786009)(83506002)(68736007)(65806001)(65956001)(33646002)(105586002)(31696002)(97736004)(86362001)(106356001)(66066001)(47776003)(64126003)(50466002)(2906002)(53546010)(6506006)(6246003)(2486003)(52116002)(316002)(76176011)(4326008)(54356011)(23676004)(52146003)(6486002)(58126008)(16526018);DIR:OUT;SFP:1102;SCL:1;SRVR:VI1PR0801MB1343;H:localhost.localdomain;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtWSTFQUjA4MDFNQjEzNDM7MjM6UG1oVElqRE9BVmFJMnFjZnltMUxEYXlW?= =?utf-8?B?RmN1eEJXSndZSG1tS3FETUd1NXZZenlLUVlNcXpxR0hTckRVMEw2OGNURC8v?= =?utf-8?B?dmVUR3V1ZnZxNkFWZkd2dUFYRmN1NGFHbCtIaTlobFBKRmZzbHdYbXlCdStB?= =?utf-8?B?WHpqa3hGSkpJYkFSak5kNU5sRFhGMGhXMVc2MHBlWlVxNW85dlg5NGdrU01v?= =?utf-8?B?amtnb2twaHdZUGNxTXBlcWJpT0d3OWN3SGw4bmF3RHZ6bjJ1K3k2TEZkSWYz?= =?utf-8?B?YXFlRlVnbmMwNGJnTlI5alV4S2hjR09JMWp4Uyt2QVByMy9OaFdhbHFPK1gy?= =?utf-8?B?SUJhZ1V1K0VEcGRJdkN1aFZLOVZjQ3BGZmZiYmlPanlCN0tNQWdMVThhcFd2?= =?utf-8?B?TGxkMmE3TFl3dlQ0U3lRb3kzbHhxbmNUbTY2eDVoMG5Fam95ckJzamRFWlpR?= =?utf-8?B?WlEvK1E3cUZ5cjd0bmV5cWM2TG1OYkswVkVUU3pIK29oNVB0UTRGZS8rT216?= =?utf-8?B?MVd0T2NPMGpGWG1kMEp0bHRFRldLRnlCR0x0TkNCejlieTlQQWZWTHZHQ3Zl?= =?utf-8?B?R2NhK1NOaWl0UGtNQ1p1eGJRWjhPVjA1WWJLRE1WZy9HTDZDMU5la3BiVHhW?= =?utf-8?B?V3NhczFDeWJGcWN5NGZDK0RkbnZZZEl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Wv49xm9kMLcLCusAO2RzSoksJB4HMneTMRI/H/xUARJOZc/xr6GTgu6NyfzVorPUJPCxOy9KpNNVvExIeXFvBeEpjXSBE5ydpSvkVw82kRxYz8J6s457wwuVbq5geN2sVcH2H5x8zPfQEyzMNQKCdsaQNF8vZV4ddP9xmPuoY8D+YF8BGZa43WJ9DQHCUCMFH5FkXrU3ZY7BGjxndRQHP SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1;VI1PR0801MB1343;20:bqPFn8IZgbNx0gkBb/N6dV2mqZdAE8fEwemLVcAPe9kZqf5RkmZIGQwDT+PfvWEpyvxvVNpdcRf6H/T42fQy1BtHR1KrATNy+eNRIurHDjONoTw4KWLqLEvAXlx+tw8m5TBMTzy2zzcjeIj7YUtbssWBiA23jB8HNRkvLXw6Jx4= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Dec 2017 21:27:45.5887 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 902f8c23-0c49-47cc-0f8a-08d53b5ddcdc X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0801MB1343 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1878 Lines: 57 Hi, Benjamin, On 04.12.2017 19:52, Benjamin LaHaise wrote: > Hi Kirill, > > On Mon, Dec 04, 2017 at 07:12:51PM +0300, Kirill Tkhai wrote: >> Hi, >> >> this patch set introduces accounting aio_nr and aio_max_nr per blkio cgroup. >> It may be used to limit number of aio requests, which are available for >> a cgroup, and could be useful for containers. >> >> The accounting is hierarchical, and aio contexts, allocated in child cgroup, >> are accounted in parent cgroups too. >> >> Also, new cgroup file "io.aio_nr" is introduced. It's used to set cgroup >> aio requests limit, to show current limit and number of currenly occupied >> requests. > > Where are your test cases to check this functionality in the libaio test > suite? I tried to find actual libaio test suite repository url in google, but there is no certain answer. Also, there is no information in kernel anywhere (I hope I grepped right). Could you please provide url where actual upstream libaio could be obtained? Kirill > > -ben > >> Patches 1-3 are refactoring. >> Patch 4 is the place where the accounting actually introduced. >> Patch 5 adds "io.aio_nr" file. >> >> --- >> >> Kirill Tkhai (5): >> aio: Move aio_nr increment to separate function >> aio: Export aio_nr_lock and aio_max_nr initial value to include/linux/aio.h >> blkcg: Add blkcg::blkg_aio_nr and blkcg::blkg_aio_max_nr >> blkcg: Charge aio requests in blkio cgroup hierarchy >> blkcg: Add cgroup file to configure blkcg::blkg_aio_max_nr >> >> >> block/blk-cgroup.c | 88 +++++++++++++++++++++++++- >> fs/aio.c | 151 ++++++++++++++++++++++++++++++++++++++++---- >> include/linux/aio.h | 21 ++++++ >> include/linux/blk-cgroup.h | 4 + >> 4 files changed, 247 insertions(+), 17 deletions(-) >> >> -- >> Signed-off-by: Kirill Tkhai >> >