From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Google-Smtp-Source: AH8x22692VkjGeSSxCOZe9ngX320LDG9zjiiRWRjOsipHqR1E2knwdJFCUT24YQlFQ+G09B6ndt7 ARC-Seal: i=1; a=rsa-sha256; t=1516995716; cv=none; d=google.com; s=arc-20160816; b=jbURKNr3CSg6BKSsr3EOJmas7X1VkFoch+WzWxDhvRN3MzVPxXM6o2kRY5oWXXV+6B 1m5TL9zm1TFTWiY2TzqkWyw7edDhg5mEnuEmflflb+PJ52zd87DcuJgm5EFL3dxSJMkn klVfMv+2JLgnmIkFAeiCVPbxhxuhbwy/VGoNGkFkYJg6caOcrqHEgIJwQa+a+SMl3YZY SRoeUo7TdefzQB4z/GAagUDXQaXKybmX9xdGhtJPLbR1kQH4//v/KEpj/7wJKrzduSdu /Smpr2CBOyJ9UI8XB9eNIHWwcwKg6drKIloIH15ZGR7GTpr0hLJxH4BOOTUif9lBMuif phXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=subject:content-transfer-encoding:content-language:in-reply-to :mime-version:user-agent:date:message-id:from:references:cc:to :delivered-to:list-id:list-subscribe:list-unsubscribe:list-help :list-post:precedence:mailing-list:arc-authentication-results; bh=hytk8LBlUwVnau2y2Vo9pWamiDOUsy4mKgXNp/nLzKk=; b=ArAvv2Y+QXzjr0L7GU2/FW9uNIkdiyfmrREYENkE8Peidet6UFmyBfb/czoX7ApGeC l9PJ80gwPcX2mUCPxK41BKqaIjP0nDzKwIf6pu5wN5a1ZG8an/LqJurdyXiHqmM67T7R NnfVpwPRMazfZ6Z3+EV4quOUl799jjD/1DcL9Y4HutKhsn9sSLLeISl4ECLdgsKFoQ92 5aYLIb/NZ0jOqW4mTgj55dgM40298a24pGQu1uO7FxJY8DdQDUGkPiYBydvatErQRfG+ YUzBywFu6J2X8AvPhF1MpjLlC+suJ7vqvLLprisfQ1E/UXhvkzEFNaU3bddDdecPcJDL 9/1w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of kernel-hardening-return-11457-gregkh=linuxfoundation.org@lists.openwall.com designates 195.42.179.200 as permitted sender) smtp.mailfrom=kernel-hardening-return-11457-gregkh=linuxfoundation.org@lists.openwall.com Authentication-Results: mx.google.com; spf=pass (google.com: domain of kernel-hardening-return-11457-gregkh=linuxfoundation.org@lists.openwall.com designates 195.42.179.200 as permitted sender) smtp.mailfrom=kernel-hardening-return-11457-gregkh=linuxfoundation.org@lists.openwall.com Mailing-List: contact kernel-hardening-help@lists.openwall.com; run by ezmlm List-Post: List-Help: List-Unsubscribe: List-Subscribe: To: , , , , , CC: , , , , References: <20180124175631.22925-1-igor.stoppa@huawei.com> <20180124175631.22925-5-igor.stoppa@huawei.com> From: Igor Stoppa Message-ID: Date: Fri, 26 Jan 2018 21:41:35 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <20180124175631.22925-5-igor.stoppa@huawei.com> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.122.225.51] X-CFilter-Loop: Reflected Subject: [kernel-hardening] Re: [PATCH 4/6] Protectable Memory X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: =?utf-8?q?1590497635371449856?= X-GMAIL-MSGID: =?utf-8?q?1590685300571432119?= X-Mailing-List: linux-kernel@vger.kernel.org List-ID: On 24/01/18 19:56, Igor Stoppa wrote: [...] > +bool pmalloc_prealloc(struct gen_pool *pool, size_t size) > +{ [...] > +abort: > + vfree(chunk); this should be vfree_atomic() [...] > +void *pmalloc(struct gen_pool *pool, size_t size, gfp_t gfp) > +{ [...] > +free: > + vfree(chunk); and this one too I will fix them in the next iteration. I am waiting to see if any more comments arrive. Otherwise, I'll send it out probably next Tuesday. -- igor From mboxrd@z Thu Jan 1 00:00:00 1970 From: igor.stoppa@huawei.com (Igor Stoppa) Date: Fri, 26 Jan 2018 21:41:35 +0200 Subject: [PATCH 4/6] Protectable Memory In-Reply-To: <20180124175631.22925-5-igor.stoppa@huawei.com> References: <20180124175631.22925-1-igor.stoppa@huawei.com> <20180124175631.22925-5-igor.stoppa@huawei.com> Message-ID: To: linux-security-module@vger.kernel.org List-Id: linux-security-module.vger.kernel.org On 24/01/18 19:56, Igor Stoppa wrote: [...] > +bool pmalloc_prealloc(struct gen_pool *pool, size_t size) > +{ [...] > +abort: > + vfree(chunk); this should be vfree_atomic() [...] > +void *pmalloc(struct gen_pool *pool, size_t size, gfp_t gfp) > +{ [...] > +free: > + vfree(chunk); and this one too I will fix them in the next iteration. I am waiting to see if any more comments arrive. Otherwise, I'll send it out probably next Tuesday. -- igor -- To unsubscribe from this list: send the line "unsubscribe linux-security-module" in the body of a message to majordomo at vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f70.google.com (mail-wm0-f70.google.com [74.125.82.70]) by kanga.kvack.org (Postfix) with ESMTP id 4CCD26B000C for ; Fri, 26 Jan 2018 14:41:38 -0500 (EST) Received: by mail-wm0-f70.google.com with SMTP id f3so846349wmc.8 for ; Fri, 26 Jan 2018 11:41:38 -0800 (PST) Received: from huawei.com (lhrrgout.huawei.com. [194.213.3.17]) by mx.google.com with ESMTPS id v79si3526072wrb.43.2018.01.26.11.41.37 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 26 Jan 2018 11:41:37 -0800 (PST) Subject: Re: [PATCH 4/6] Protectable Memory References: <20180124175631.22925-1-igor.stoppa@huawei.com> <20180124175631.22925-5-igor.stoppa@huawei.com> From: Igor Stoppa Message-ID: Date: Fri, 26 Jan 2018 21:41:35 +0200 MIME-Version: 1.0 In-Reply-To: <20180124175631.22925-5-igor.stoppa@huawei.com> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: owner-linux-mm@kvack.org List-ID: To: jglisse@redhat.com, keescook@chromium.org, mhocko@kernel.org, labbott@redhat.com, hch@infradead.org, willy@infradead.org Cc: cl@linux.com, linux-security-module@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, kernel-hardening@lists.openwall.com On 24/01/18 19:56, Igor Stoppa wrote: [...] > +bool pmalloc_prealloc(struct gen_pool *pool, size_t size) > +{ [...] > +abort: > + vfree(chunk); this should be vfree_atomic() [...] > +void *pmalloc(struct gen_pool *pool, size_t size, gfp_t gfp) > +{ [...] > +free: > + vfree(chunk); and this one too I will fix them in the next iteration. I am waiting to see if any more comments arrive. Otherwise, I'll send it out probably next Tuesday. -- igor -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org From mboxrd@z Thu Jan 1 00:00:00 1970 References: <20180124175631.22925-1-igor.stoppa@huawei.com> <20180124175631.22925-5-igor.stoppa@huawei.com> From: Igor Stoppa Message-ID: Date: Fri, 26 Jan 2018 21:41:35 +0200 MIME-Version: 1.0 In-Reply-To: <20180124175631.22925-5-igor.stoppa@huawei.com> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Subject: [kernel-hardening] Re: [PATCH 4/6] Protectable Memory To: jglisse@redhat.com, keescook@chromium.org, mhocko@kernel.org, labbott@redhat.com, hch@infradead.org, willy@infradead.org Cc: cl@linux.com, linux-security-module@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, kernel-hardening@lists.openwall.com List-ID: On 24/01/18 19:56, Igor Stoppa wrote: [...] > +bool pmalloc_prealloc(struct gen_pool *pool, size_t size) > +{ [...] > +abort: > + vfree(chunk); this should be vfree_atomic() [...] > +void *pmalloc(struct gen_pool *pool, size_t size, gfp_t gfp) > +{ [...] > +free: > + vfree(chunk); and this one too I will fix them in the next iteration. I am waiting to see if any more comments arrive. Otherwise, I'll send it out probably next Tuesday. -- igor