diff mbox series

drivers: tty: serial: Add missing of_node_put() in serial-tegra.c

Message ID 20220615104833.3963552-1-windhl@126.com
State Not Applicable
Headers show
Series drivers: tty: serial: Add missing of_node_put() in serial-tegra.c | expand

Commit Message

Liang He June 15, 2022, 10:48 a.m. UTC
In tegra_uart_init(), of_find_matching_node() will return a node
pointer with refcount incremented. We should use of_node_put()
when it is not used anymore.

Signed-off-by: heliang <windhl@126.com>
---
 drivers/tty/serial/serial-tegra.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Dave Airlie June 15, 2022, 8:23 p.m. UTC | #1
On Wed, 15 Jun 2022 at 20:53, Greg KH <gregkh@linuxfoundation.org> wrote:
>
> On Wed, Jun 15, 2022 at 06:48:33PM +0800, heliang wrote:
> > In tegra_uart_init(), of_find_matching_node() will return a node
> > pointer with refcount incremented. We should use of_node_put()
> > when it is not used anymore.
> >
> > Signed-off-by: heliang <windhl@126.com>
>
> We need a real name please, one you sign documents with.

How do we enforce that? What if Wong, Adele or Beyonce submit a patch?

What happens if that patch gets reposted, with S-o-b: He Liang
<windhl@126.com> or Hel Iang, Heli Ang? Do you know any of those are
real names? What happens if they post a real name in
Mandarin/Thai/Cyrillic, can you validate it?

Really we require you have an identity attached to an email. If there
is a problem in the future, we'd prefer the email continues to work so
that you are contactable. If you are submitting a small amount of
changes it's probably never going to matter. If you are submitting
larger bodies of work of course it would be good to have a company or
larger org attached to track things down legally later, but again that
isn't always possible.

I don't think alienating the numerous developers who no longer use
their legal names are identified by one name, but haven't changed
their legal one yet people who get married and change their legal name
but don't change their contribution name and I could run this sentence
on forever.

Dave.
Daniel Vetter June 15, 2022, 8:30 p.m. UTC | #2
On Wed, 15 Jun 2022 at 22:23, Dave Airlie <airlied@gmail.com> wrote:
>
> On Wed, 15 Jun 2022 at 20:53, Greg KH <gregkh@linuxfoundation.org> wrote:
> >
> > On Wed, Jun 15, 2022 at 06:48:33PM +0800, heliang wrote:
> > > In tegra_uart_init(), of_find_matching_node() will return a node
> > > pointer with refcount incremented. We should use of_node_put()
> > > when it is not used anymore.
> > >
> > > Signed-off-by: heliang <windhl@126.com>
> >
> > We need a real name please, one you sign documents with.
>
> How do we enforce that? What if Wong, Adele or Beyonce submit a patch?
>
> What happens if that patch gets reposted, with S-o-b: He Liang
> <windhl@126.com> or Hel Iang, Heli Ang? Do you know any of those are
> real names? What happens if they post a real name in
> Mandarin/Thai/Cyrillic, can you validate it?
>
> Really we require you have an identity attached to an email. If there
> is a problem in the future, we'd prefer the email continues to work so
> that you are contactable. If you are submitting a small amount of
> changes it's probably never going to matter. If you are submitting
> larger bodies of work of course it would be good to have a company or
> larger org attached to track things down legally later, but again that
> isn't always possible.
>
> I don't think alienating the numerous developers who no longer use
> their legal names are identified by one name, but haven't changed
> their legal one yet people who get married and change their legal name
> but don't change their contribution name and I could run this sentence
> on forever.

Yeah like absolute best case trying to "enforce" this just results in
encouraging people to come up with entirely fake but English looking
names for themselves. Which ... just no.
-Daniel
Greg KH June 16, 2022, 8:42 a.m. UTC | #3
On Thu, Jun 16, 2022 at 06:23:26AM +1000, Dave Airlie wrote:
> On Wed, 15 Jun 2022 at 20:53, Greg KH <gregkh@linuxfoundation.org> wrote:
> >
> > On Wed, Jun 15, 2022 at 06:48:33PM +0800, heliang wrote:
> > > In tegra_uart_init(), of_find_matching_node() will return a node
> > > pointer with refcount incremented. We should use of_node_put()
> > > when it is not used anymore.
> > >
> > > Signed-off-by: heliang <windhl@126.com>
> >
> > We need a real name please, one you sign documents with.
> 
> How do we enforce that? What if Wong, Adele or Beyonce submit a patch?

As per our rules in the kernel, we can not accept a signed-off-by by a
known anonymous person.  When you can obviously see that the name is
incorrect (as has happened recently with different names being used for
the from: and the s-o-b lines in the email address), you have to ask for
clarification.  It's something that all maintainers should be doing.

> What happens if that patch gets reposted, with S-o-b: He Liang
> <windhl@126.com> or Hel Iang, Heli Ang? Do you know any of those are
> real names? What happens if they post a real name in
> Mandarin/Thai/Cyrillic, can you validate it?

I would love for people to use their names in their native language,
there's no need to make up english-sounding names at all.  We have many
examples of this in commits already, I would be happy if we get more.

And yes, validating names in those languages is usually not very
difficult.

thanks,

greg k-h
Greg KH June 16, 2022, 8:43 a.m. UTC | #4
On Wed, Jun 15, 2022 at 10:30:47PM +0200, Daniel Vetter wrote:
> On Wed, 15 Jun 2022 at 22:23, Dave Airlie <airlied@gmail.com> wrote:
> >
> > On Wed, 15 Jun 2022 at 20:53, Greg KH <gregkh@linuxfoundation.org> wrote:
> > >
> > > On Wed, Jun 15, 2022 at 06:48:33PM +0800, heliang wrote:
> > > > In tegra_uart_init(), of_find_matching_node() will return a node
> > > > pointer with refcount incremented. We should use of_node_put()
> > > > when it is not used anymore.
> > > >
> > > > Signed-off-by: heliang <windhl@126.com>
> > >
> > > We need a real name please, one you sign documents with.
> >
> > How do we enforce that? What if Wong, Adele or Beyonce submit a patch?
> >
> > What happens if that patch gets reposted, with S-o-b: He Liang
> > <windhl@126.com> or Hel Iang, Heli Ang? Do you know any of those are
> > real names? What happens if they post a real name in
> > Mandarin/Thai/Cyrillic, can you validate it?
> >
> > Really we require you have an identity attached to an email. If there
> > is a problem in the future, we'd prefer the email continues to work so
> > that you are contactable. If you are submitting a small amount of
> > changes it's probably never going to matter. If you are submitting
> > larger bodies of work of course it would be good to have a company or
> > larger org attached to track things down legally later, but again that
> > isn't always possible.
> >
> > I don't think alienating the numerous developers who no longer use
> > their legal names are identified by one name, but haven't changed
> > their legal one yet people who get married and change their legal name
> > but don't change their contribution name and I could run this sentence
> > on forever.
> 
> Yeah like absolute best case trying to "enforce" this just results in
> encouraging people to come up with entirely fake but English looking
> names for themselves. Which ... just no.

Agree, again, I'd prefer to take real names in native languages, our
tools can handle that just fine.  No need to make up anything.

thanks,

greg k-h
Liang He June 16, 2022, 8:52 a.m. UTC | #5
At 2022-06-16 16:43:43, "Greg KH" <gregkh@linuxfoundation.org> wrote:
>On Wed, Jun 15, 2022 at 10:30:47PM +0200, Daniel Vetter wrote:
>> On Wed, 15 Jun 2022 at 22:23, Dave Airlie <airlied@gmail.com> wrote:
>> >
>> > On Wed, 15 Jun 2022 at 20:53, Greg KH <gregkh@linuxfoundation.org> wrote:
>> > >
>> > > On Wed, Jun 15, 2022 at 06:48:33PM +0800, heliang wrote:
>> > > > In tegra_uart_init(), of_find_matching_node() will return a node
>> > > > pointer with refcount incremented. We should use of_node_put()
>> > > > when it is not used anymore.
>> > > >
>> > > > Signed-off-by: heliang <windhl@126.com>
>> > >
>> > > We need a real name please, one you sign documents with.
>> >
>> > How do we enforce that? What if Wong, Adele or Beyonce submit a patch?
>> >
>> > What happens if that patch gets reposted, with S-o-b: He Liang
>> > <windhl@126.com> or Hel Iang, Heli Ang? Do you know any of those are
>> > real names? What happens if they post a real name in
>> > Mandarin/Thai/Cyrillic, can you validate it?
>> >
>> > Really we require you have an identity attached to an email. If there
>> > is a problem in the future, we'd prefer the email continues to work so
>> > that you are contactable. If you are submitting a small amount of
>> > changes it's probably never going to matter. If you are submitting
>> > larger bodies of work of course it would be good to have a company or
>> > larger org attached to track things down legally later, but again that
>> > isn't always possible.
>> >
>> > I don't think alienating the numerous developers who no longer use
>> > their legal names are identified by one name, but haven't changed
>> > their legal one yet people who get married and change their legal name
>> > but don't change their contribution name and I could run this sentence
>> > on forever.
>> 
>> Yeah like absolute best case trying to "enforce" this just results in
>> encouraging people to come up with entirely fake but English looking
>> names for themselves. Which ... just no.
>
>Agree, again, I'd prefer to take real names in native languages, our
>tools can handle that just fine.  No need to make up anything.
>
>thanks,
>
>greg k-h

hi, Greg K-H, 

I have resent a new patch for my commit of tegra_uart_init() bug with my real name for Sob.

So there is anyother thing I should do?
Conor Dooley June 16, 2022, 9:20 a.m. UTC | #6
On 16/06/2022 09:52, Liang He wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
> 
> At 2022-06-16 16:43:43, "Greg KH" <gregkh@linuxfoundation.org> wrote:
>> On Wed, Jun 15, 2022 at 10:30:47PM +0200, Daniel Vetter wrote:
>>> On Wed, 15 Jun 2022 at 22:23, Dave Airlie <airlied@gmail.com> wrote:
>>>>
>>>> On Wed, 15 Jun 2022 at 20:53, Greg KH <gregkh@linuxfoundation.org> wrote:
>>>>>
>>>>> On Wed, Jun 15, 2022 at 06:48:33PM +0800, heliang wrote:
>>>>>> In tegra_uart_init(), of_find_matching_node() will return a node
>>>>>> pointer with refcount incremented. We should use of_node_put()
>>>>>> when it is not used anymore.
>>>>>>
>>>>>> Signed-off-by: heliang <windhl@126.com>
>>>>>
>>>>> We need a real name please, one you sign documents with.
>>>>
>>>> How do we enforce that? What if Wong, Adele or Beyonce submit a patch?
>>>>
>>>> What happens if that patch gets reposted, with S-o-b: He Liang
>>>> <windhl@126.com> or Hel Iang, Heli Ang? Do you know any of those are
>>>> real names? What happens if they post a real name in
>>>> Mandarin/Thai/Cyrillic, can you validate it?
>>>>
>>>> Really we require you have an identity attached to an email. If there
>>>> is a problem in the future, we'd prefer the email continues to work so
>>>> that you are contactable. If you are submitting a small amount of
>>>> changes it's probably never going to matter. If you are submitting
>>>> larger bodies of work of course it would be good to have a company or
>>>> larger org attached to track things down legally later, but again that
>>>> isn't always possible.
>>>>
>>>> I don't think alienating the numerous developers who no longer use
>>>> their legal names are identified by one name, but haven't changed
>>>> their legal one yet people who get married and change their legal name
>>>> but don't change their contribution name and I could run this sentence
>>>> on forever.
>>>
>>> Yeah like absolute best case trying to "enforce" this just results in
>>> encouraging people to come up with entirely fake but English looking
>>> names for themselves. Which ... just no.
>>
>> Agree, again, I'd prefer to take real names in native languages, our
>> tools can handle that just fine.  No need to make up anything.

Since this is the only mail from this chain in my inbox and I asked the
same question as Greg on other patches:
I think it is pretty reasonable to /ask/ if something is not a real name
when you see something like "heliang <windhl@126.com>" where there's a
clear difference. And "It is my real name" is a perfectly reasonable
response /shrug.
Trust but verify right? It's not like I'm gonna argue the toss with
someone if they say it is their real name...

Thanks,
Conchubhar ;)

>>
>> thanks,
>>
>> greg k-h
> 
> hi, Greg K-H,
> 
> I have resent a new patch for my commit of tegra_uart_init() bug with my real name for Sob.
> 
> So there is anyother thing I should do?
Liang He June 16, 2022, 9:39 a.m. UTC | #7
At 2022-06-16 17:20:24, Conor.Dooley@microchip.com wrote:
>On 16/06/2022 09:52, Liang He wrote:
>> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
>> 
>> At 2022-06-16 16:43:43, "Greg KH" <gregkh@linuxfoundation.org> wrote:
>>> On Wed, Jun 15, 2022 at 10:30:47PM +0200, Daniel Vetter wrote:
>>>> On Wed, 15 Jun 2022 at 22:23, Dave Airlie <airlied@gmail.com> wrote:
>>>>>
>>>>> On Wed, 15 Jun 2022 at 20:53, Greg KH <gregkh@linuxfoundation.org> wrote:
>>>>>>
>>>>>> On Wed, Jun 15, 2022 at 06:48:33PM +0800, heliang wrote:
>>>>>>> In tegra_uart_init(), of_find_matching_node() will return a node
>>>>>>> pointer with refcount incremented. We should use of_node_put()
>>>>>>> when it is not used anymore.
>>>>>>>
>>>>>>> Signed-off-by: heliang <windhl@126.com>
>>>>>>
>>>>>> We need a real name please, one you sign documents with.
>>>>>
>>>>> How do we enforce that? What if Wong, Adele or Beyonce submit a patch?
>>>>>
>>>>> What happens if that patch gets reposted, with S-o-b: He Liang
>>>>> <windhl@126.com> or Hel Iang, Heli Ang? Do you know any of those are
>>>>> real names? What happens if they post a real name in
>>>>> Mandarin/Thai/Cyrillic, can you validate it?
>>>>>
>>>>> Really we require you have an identity attached to an email. If there
>>>>> is a problem in the future, we'd prefer the email continues to work so
>>>>> that you are contactable. If you are submitting a small amount of
>>>>> changes it's probably never going to matter. If you are submitting
>>>>> larger bodies of work of course it would be good to have a company or
>>>>> larger org attached to track things down legally later, but again that
>>>>> isn't always possible.
>>>>>
>>>>> I don't think alienating the numerous developers who no longer use
>>>>> their legal names are identified by one name, but haven't changed
>>>>> their legal one yet people who get married and change their legal name
>>>>> but don't change their contribution name and I could run this sentence
>>>>> on forever.
>>>>
>>>> Yeah like absolute best case trying to "enforce" this just results in
>>>> encouraging people to come up with entirely fake but English looking
>>>> names for themselves. Which ... just no.
>>>
>>> Agree, again, I'd prefer to take real names in native languages, our
>>> tools can handle that just fine.  No need to make up anything.
>
>Since this is the only mail from this chain in my inbox and I asked the
>same question as Greg on other patches:
>I think it is pretty reasonable to /ask/ if something is not a real name
>when you see something like "heliang <windhl@126.com>" where there's a
>clear difference. And "It is my real name" is a perfectly reasonable
>response /shrug.
>Trust but verify right? It's not like I'm gonna argue the toss with
>someone if they say it is their real name...
>
>Thanks,
>Conchubhar ;)
>
>>>
>>> thanks,
>>>
>>> greg k-h
>> 
>> hi, Greg K-H,
>> 
>> I have resent a new patch for my commit of tegra_uart_init() bug with my real name for Sob.
>> 
>> So there is anyother thing I should do?
>


Sorry, Conor and Grep K-H.

I did not explain clearly and I respect all your suggestions.

I have resent with 'Liang He' as my real name for all patches which I sent with heliang yesterday.
And I use '[PATCH v2]' for there resent patches.

Sorry again.
Conor Dooley June 16, 2022, 9:43 a.m. UTC | #8
On 16/06/2022 10:39, Liang He wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
> 
> At 2022-06-16 17:20:24, Conor.Dooley@microchip.com wrote:
>> On 16/06/2022 09:52, Liang He wrote:
>>> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
>>>
>>> At 2022-06-16 16:43:43, "Greg KH" <gregkh@linuxfoundation.org> wrote:
>>>> On Wed, Jun 15, 2022 at 10:30:47PM +0200, Daniel Vetter wrote:
>>>>> On Wed, 15 Jun 2022 at 22:23, Dave Airlie <airlied@gmail.com> wrote:
>>>>>>
>>>>>> On Wed, 15 Jun 2022 at 20:53, Greg KH <gregkh@linuxfoundation.org> wrote:
>>>>>>>
>>>>>>> On Wed, Jun 15, 2022 at 06:48:33PM +0800, heliang wrote:
>>>>>>>> In tegra_uart_init(), of_find_matching_node() will return a node
>>>>>>>> pointer with refcount incremented. We should use of_node_put()
>>>>>>>> when it is not used anymore.
>>>>>>>>
>>>>>>>> Signed-off-by: heliang <windhl@126.com>
>>>>>>>
>>>>>>> We need a real name please, one you sign documents with.
>>>>>>
>>>>>> How do we enforce that? What if Wong, Adele or Beyonce submit a patch?
>>>>>>
>>>>>> What happens if that patch gets reposted, with S-o-b: He Liang
>>>>>> <windhl@126.com> or Hel Iang, Heli Ang? Do you know any of those are
>>>>>> real names? What happens if they post a real name in
>>>>>> Mandarin/Thai/Cyrillic, can you validate it?
>>>>>>
>>>>>> Really we require you have an identity attached to an email. If there
>>>>>> is a problem in the future, we'd prefer the email continues to work so
>>>>>> that you are contactable. If you are submitting a small amount of
>>>>>> changes it's probably never going to matter. If you are submitting
>>>>>> larger bodies of work of course it would be good to have a company or
>>>>>> larger org attached to track things down legally later, but again that
>>>>>> isn't always possible.
>>>>>>
>>>>>> I don't think alienating the numerous developers who no longer use
>>>>>> their legal names are identified by one name, but haven't changed
>>>>>> their legal one yet people who get married and change their legal name
>>>>>> but don't change their contribution name and I could run this sentence
>>>>>> on forever.
>>>>>
>>>>> Yeah like absolute best case trying to "enforce" this just results in
>>>>> encouraging people to come up with entirely fake but English looking
>>>>> names for themselves. Which ... just no.
>>>>
>>>> Agree, again, I'd prefer to take real names in native languages, our
>>>> tools can handle that just fine.  No need to make up anything.
>>
>> Since this is the only mail from this chain in my inbox and I asked the
>> same question as Greg on other patches:
>> I think it is pretty reasonable to /ask/ if something is not a real name
>> when you see something like "heliang <windhl@126.com>" where there's a
>> clear difference. And "It is my real name" is a perfectly reasonable
>> response /shrug.
>> Trust but verify right? It's not like I'm gonna argue the toss with
>> someone if they say it is their real name...
>>
>> Thanks,
>> Conchubhar ;)
>>
>>>>
>>>> thanks,
>>>>
>>>> greg k-h
>>>
>>> hi, Greg K-H,
>>>
>>> I have resent a new patch for my commit of tegra_uart_init() bug with my real name for Sob.
>>>
>>> So there is anyother thing I should do?
>>
> 
> 
> Sorry, Conor and Grep K-H.

No need to apologise, my mail was directed at Daniel & Dave not you :)

> 
> I did not explain clearly and I respect all your suggestions.
> 
> I have resent with 'Liang He' as my real name for all patches which I sent with heliang yesterday.
> And I use '[PATCH v2]' for there resent patches.
> 
> Sorry again.
diff mbox series

Patch

diff --git a/drivers/tty/serial/serial-tegra.c b/drivers/tty/serial/serial-tegra.c
index d942ab152f5a..5c4850a3762c 100644
--- a/drivers/tty/serial/serial-tegra.c
+++ b/drivers/tty/serial/serial-tegra.c
@@ -1667,6 +1667,7 @@  static int __init tegra_uart_init(void)
 	node = of_find_matching_node(NULL, tegra_uart_of_match);
 	if (node)
 		match = of_match_node(tegra_uart_of_match, node);
+	of_node_put(node);
 	if (match)
 		cdata = match->data;
 	if (cdata)