From patchwork Wed Oct 11 14:31:43 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Berg X-Patchwork-Id: 9999783 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B9A8B602BF for ; Wed, 11 Oct 2017 14:31:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A88C1289F7 for ; Wed, 11 Oct 2017 14:31:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9D2D228A51; Wed, 11 Oct 2017 14:31:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3304F289F7 for ; Wed, 11 Oct 2017 14:31:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751816AbdJKObx (ORCPT ); Wed, 11 Oct 2017 10:31:53 -0400 Received: from s3.sipsolutions.net ([144.76.63.242]:48806 "EHLO sipsolutions.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751712AbdJKObx (ORCPT ); Wed, 11 Oct 2017 10:31:53 -0400 Received: by sipsolutions.net with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1e2I33-0005BU-C9; Wed, 11 Oct 2017 16:31:49 +0200 From: Johannes Berg To: backports@vger.kernel.org Cc: Johannes Berg Subject: [PATCH 1/5] backports: fix some dev_coredumpm() problem Date: Wed, 11 Oct 2017 16:31:43 +0200 Message-Id: <20171011143147.3337-1-johannes@sipsolutions.net> X-Mailer: git-send-email 2.14.2 Sender: backports-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: backports@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Johannes Berg Sometimes the argument is const, sometimes not, just cast away that difference. Signed-off-by: Johannes Berg --- backport/compat/backport-4.7.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/backport/compat/backport-4.7.c b/backport/compat/backport-4.7.c index b064707767c6..372951b60382 100644 --- a/backport/compat/backport-4.7.c +++ b/backport/compat/backport-4.7.c @@ -176,7 +176,9 @@ void dev_coredumpsg(struct device *dev, struct scatterlist *table, size_t datalen, gfp_t gfp) { dev_coredumpm(dev, THIS_MODULE, table, datalen, gfp, - devcd_read_from_sgtable, devcd_free_sgtable); + /* cast away some const problems */ + (void *)devcd_read_from_sgtable, + (void *)devcd_free_sgtable); } EXPORT_SYMBOL_GPL(dev_coredumpsg); #endif /* >= 3.18.0 */