Linux RDMA and InfiniBand development
 help / color / mirror / Atom feed
From: Zhu Yanjun <yanjun.zhu@linux.dev>
To: Jason Gunthorpe <jgg@ziepe.ca>
Cc: zyjzyj2000@gmail.com, leon@kernel.org, linux-rdma@vger.kernel.org
Subject: Re: [PATCH 1/1] RDMA/rxe: Make pr_fmt work
Date: Thu, 4 Apr 2024 20:03:35 +0200	[thread overview]
Message-ID: <be9584b6-85fc-46bb-87b8-18ca6103a5a4@linux.dev> (raw)
In-Reply-To: <7a2a41c2-c8ef-402d-933a-2b2d8a956207@linux.dev>


在 2024/4/4 20:01, Zhu Yanjun 写道:
>
>
> 在 2024/4/4 16:59, Jason Gunthorpe 写道:
>> On Wed, Mar 27, 2024 at 08:40:54PM +0100, Zhu Yanjun wrote:
>>> 在 2024/3/27 14:08, Jason Gunthorpe 写道:
>>>> On Sat, Mar 23, 2024 at 09:31:39AM +0100, Yanjun.Zhu wrote:
>>>>> From: Zhu Yanjun<yanjun.zhu@linux.dev>
>>>>>
>>>>> If the definition of pr_fmt is before the header file. The pr_fmt
>>>>> will be overwritten by the header file. So move the definition of
>>>>> pr_fmt to the below of the header file.
>>>> what header file?
>>> include/linux/printk.h
>>>
>>> Because this driver will finally call printk function to output the logs,
>>> the header file include/linux/printk.h needs be included.
>>>
>>> In include/linux/printk.h, pr_fmt is defined.
>> This doesn't make sense, printk.h has:
>>
>> #ifndef pr_fmt
>> #define pr_fmt(fmt) fmt
>> #endif
>>
>> Before or after printk.h should not have an impact.


Sorry. The previous mail is not sent successfully. I resend it.

> #ifndef pr_fmt
>
> ...
>
> #endif
>
> The above will not undefine pr_fmt.
>
> #undef pr_fmt will undefine pr_fmt.
>
> This link explains the above in details.
>
https://www.techonthenet.com/c_language/directives/ifndef.php
>
> Thanks a lot for your comments.
>
> Zhu Yanjun
>
>> Jason

  parent reply	other threads:[~2024-04-04 18:03 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-23  8:31 [PATCH 1/1] RDMA/rxe: Make pr_fmt work Yanjun.Zhu
2024-03-24 11:43 ` Greg Sword
2024-03-27 13:08 ` Jason Gunthorpe
2024-03-27 19:40   ` Zhu Yanjun
2024-04-04 14:59     ` Jason Gunthorpe
     [not found]       ` <7a2a41c2-c8ef-402d-933a-2b2d8a956207@linux.dev>
2024-04-04 18:03         ` Zhu Yanjun [this message]
2024-04-04 23:59           ` Jason Gunthorpe
2024-04-06 16:35             ` Zhu Yanjun
2024-04-08 14:08               ` Jason Gunthorpe
2024-04-02 17:45 ` Leon Romanovsky
2024-04-03 16:46   ` Zhu Yanjun

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=be9584b6-85fc-46bb-87b8-18ca6103a5a4@linux.dev \
    --to=yanjun.zhu@linux.dev \
    --cc=jgg@ziepe.ca \
    --cc=leon@kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=zyjzyj2000@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox