From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751466AbdISNi4 convert rfc822-to-8bit (ORCPT ); Tue, 19 Sep 2017 09:38:56 -0400 Received: from smtp-out4.electric.net ([192.162.216.182]:57183 "EHLO smtp-out4.electric.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750972AbdISNiz (ORCPT ); Tue, 19 Sep 2017 09:38:55 -0400 From: David Laight To: "'Sergey Senozhatsky'" , Helge Deller CC: Fenghua Yu , "Luck, Tony" , "linux-ia64@vger.kernel.org" , Petr Mladek , Jessica Yu , "James E . J . Bottomley" , Steven Rostedt , "Alexei Starovoitov" , Sergey Senozhatsky , Paul Mackerras , "Andrew Morton" , "linuxppc-dev@lists.ozlabs.org" , "linux-kernel@vger.kernel.org" Subject: RE: [PATCH 0/5] [RFC] printk/ia64/ppc64/parisc64: let's deprecate %pF/%pf printk specifiers Thread-Topic: [PATCH 0/5] [RFC] printk/ia64/ppc64/parisc64: let's deprecate %pF/%pf printk specifiers Thread-Index: AQHTMOwDT4Uu8fKFA0OVdqOPpU6rUKK8Noug Date: Tue, 19 Sep 2017 13:38:42 +0000 Message-ID: <063D6719AE5E284EB5DD2968C1650D6DD007A0D0@AcuExch.aculab.com> References: <20170916035347.19705-1-sergey.senozhatsky@gmail.com> <20170918174432.4fksyzco2g6gczwe@intel.com> <20170918183902.GA30752@p100.box> <20170919020537.GA16991@jagdpanzerIV.localdomain> In-Reply-To: <20170919020537.GA16991@jagdpanzerIV.localdomain> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.202.99.200] Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-Outbound-IP: 156.67.243.126 X-Env-From: David.Laight@ACULAB.COM X-Proto: esmtps X-Revdns: X-HELO: AcuExch.aculab.com X-TLS: TLSv1:AES128-SHA:128 X-Authenticated_ID: X-PolicySMART: 3396946, 3397078 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Sergey Senozhatsky > Sent: 19 September 2017 03:06 ... > I'll simply convert everything to `unsigned long'. including the > dereference_function_descriptor() function [I believe there are > still some casts happening when we pass addr from kernel/module > dereference functions to dereference_function_descriptor(), or > when we return `void *' back to symbol resolution code, etc.) > besides, it seems that everything that uses > dereference_function_descriptor() wants `unsigned long' anyway: Using 'unsigned long' for any kind of pointer is an accident waiting do happen. It also makes it difficult to typecheck the function calls. Using 'void *' isn't any better. Either a pointer to an undefined struct, or a struct containing a single 'char' member, is likely to be safest. David