* Re: [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree [not found] <12893476522148@site> @ 2010-11-10 10:17 ` Marek Lindner 2010-11-10 16:04 ` Greg KH 0 siblings, 1 reply; 8+ messages in thread From: Marek Lindner @ 2010-11-10 10:17 UTC (permalink / raw) To: gregkh, b.a.t.m.a.n; +Cc: tklauser, siwu Greg, > The patch is only compile-tested. [..] > diff --git a/drivers/staging/batman-adv/main.c > b/drivers/staging/batman-adv/main.c index 0587940..6ea6420 100644 > --- a/drivers/staging/batman-adv/main.c > +++ b/drivers/staging/batman-adv/main.c > @@ -149,7 +149,7 @@ void dec_module_count(void) > > int compare_orig(void *data1, void *data2) > { > - return (memcmp(data1, data2, ETH_ALEN) == 0 ? 1 : 0); > + return (compare_ether_addr(data1, data2) == 0 ? 1 : 0); > } I'm wondering why you accepted this patch despite the raised objections regarding alignment problems. [1][2] Is there something you know that we overlooked ? We haven't heard from Thomas or you since the alignment question came on the table. Cheers, Marek [1]https://lists.open-mesh.org/pipermail/b.a.t.m.a.n/2010-November/003640.html [2]https://lists.open-mesh.org/pipermail/b.a.t.m.a.n/2010-November/003643.html ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree 2010-11-10 10:17 ` [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree Marek Lindner @ 2010-11-10 16:04 ` Greg KH 2010-11-10 16:46 ` Sven Eckelmann 0 siblings, 1 reply; 8+ messages in thread From: Greg KH @ 2010-11-10 16:04 UTC (permalink / raw) To: Marek Lindner; +Cc: tklauser, b.a.t.m.a.n, siwu On Wed, Nov 10, 2010 at 11:17:03AM +0100, Marek Lindner wrote: > > Greg, > > > The patch is only compile-tested. > > [..] > > > diff --git a/drivers/staging/batman-adv/main.c > > b/drivers/staging/batman-adv/main.c index 0587940..6ea6420 100644 > > --- a/drivers/staging/batman-adv/main.c > > +++ b/drivers/staging/batman-adv/main.c > > @@ -149,7 +149,7 @@ void dec_module_count(void) > > > > int compare_orig(void *data1, void *data2) > > { > > - return (memcmp(data1, data2, ETH_ALEN) == 0 ? 1 : 0); > > + return (compare_ether_addr(data1, data2) == 0 ? 1 : 0); > > } > > I'm wondering why you accepted this patch despite the raised objections > regarding alignment problems. [1][2] Because at the end of that thread, it sounded like you all agreed that this patch was acceptable. If not, then please let me know and I will revert it. thanks, greg k-h ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree 2010-11-10 16:04 ` Greg KH @ 2010-11-10 16:46 ` Sven Eckelmann 2010-11-11 1:11 ` Greg KH 2010-11-11 8:52 ` Tobias Klauser 0 siblings, 2 replies; 8+ messages in thread From: Sven Eckelmann @ 2010-11-10 16:46 UTC (permalink / raw) To: b.a.t.m.a.n; +Cc: tklauser, Greg KH, Marek Lindner, siwu [-- Attachment #1: Type: Text/Plain, Size: 1551 bytes --] On Wednesday 10 November 2010 17:04:55 Greg KH wrote: > > I'm wondering why you accepted this patch despite the raised objections > > regarding alignment problems. [1][2] > > Because at the end of that thread, it sounded like you all agreed that > this patch was acceptable. > > If not, then please let me know and I will revert it. The end of the thread was that he should remove parts of the patch and resent it - or prove that all the data is 2 bytes aligned. On Wednesday 03 November 2010 11:56:19 Sven Eckelmann wrote: [...] > > I don't think they need to be two bytes aligned, but I might be wrong. > > compare_ether_addr uses a two byte pointer to access 3x two bytes. This > makes it necessary to have all those 3 bytes aligned to 2 byte boundaries. [correction sent later: "6x two bytes aligned to 2 byte boundaries"] > Otherwise the compiler has to generate special instructions on > architectures which don't support loads on non-aligned addresses. Usually > he doesn't do it unless he has some indications that it is necessary > (__attribute__ ((packed)) for example). > > There is also documentation available on that topic in > Documentation/unaligned-memory-access.txt > > And maybe it is good to use is_broadcast_ether_addr, but leave > compare_ether_addr part open (or prove that we always have those two > operands correctly aligned). [...] None of that happened yet. And yes, this wasn't the last mail we sent to him to get some response - no answer till now. Best regards, Sven [-- Attachment #2: This is a digitally signed message part. --] [-- Type: application/pgp-signature, Size: 836 bytes --] ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree 2010-11-10 16:46 ` Sven Eckelmann @ 2010-11-11 1:11 ` Greg KH 2010-11-11 10:34 ` Marek Lindner 2010-11-11 8:52 ` Tobias Klauser 1 sibling, 1 reply; 8+ messages in thread From: Greg KH @ 2010-11-11 1:11 UTC (permalink / raw) To: Sven Eckelmann; +Cc: tklauser, b.a.t.m.a.n, Marek Lindner, siwu On Wed, Nov 10, 2010 at 05:46:37PM +0100, Sven Eckelmann wrote: > On Wednesday 10 November 2010 17:04:55 Greg KH wrote: > > > I'm wondering why you accepted this patch despite the raised objections > > > regarding alignment problems. [1][2] > > > > Because at the end of that thread, it sounded like you all agreed that > > this patch was acceptable. > > > > If not, then please let me know and I will revert it. > > The end of the thread was that he should remove parts of the patch and resent > it - or prove that all the data is 2 bytes aligned. > > > On Wednesday 03 November 2010 11:56:19 Sven Eckelmann wrote: > [...] > > > I don't think they need to be two bytes aligned, but I might be wrong. > > > > compare_ether_addr uses a two byte pointer to access 3x two bytes. This > > makes it necessary to have all those 3 bytes aligned to 2 byte boundaries. > [correction sent later: "6x two bytes aligned to 2 byte boundaries"] > > Otherwise the compiler has to generate special instructions on > > architectures which don't support loads on non-aligned addresses. Usually > > he doesn't do it unless he has some indications that it is necessary > > (__attribute__ ((packed)) for example). > > > > There is also documentation available on that topic in > > Documentation/unaligned-memory-access.txt > > > > And maybe it is good to use is_broadcast_ether_addr, but leave > > compare_ether_addr part open (or prove that we always have those two > > operands correctly aligned). > [...] > > None of that happened yet. And yes, this wasn't the last mail we sent to him > to get some response - no answer till now. Oops, my fault, I've now reverted this patch, sorry about that. thanks, greg k-h ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree 2010-11-11 1:11 ` Greg KH @ 2010-11-11 10:34 ` Marek Lindner 0 siblings, 0 replies; 8+ messages in thread From: Marek Lindner @ 2010-11-11 10:34 UTC (permalink / raw) To: b.a.t.m.a.n; +Cc: tklauser, Greg KH, siwu On Thursday 11 November 2010 02:11:37 Greg KH wrote: > > None of that happened yet. And yes, this wasn't the last mail we sent to > > him to get some response - no answer till now. > > Oops, my fault, I've now reverted this patch, sorry about that. No problem, that can happen. Thanks, Marek ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree 2010-11-10 16:46 ` Sven Eckelmann 2010-11-11 1:11 ` Greg KH @ 2010-11-11 8:52 ` Tobias Klauser [not found] ` <BAY127-W15AD53BC245C1D430CF07BCF360@phx.gbl> 2010-11-17 16:32 ` Marek Lindner 1 sibling, 2 replies; 8+ messages in thread From: Tobias Klauser @ 2010-11-11 8:52 UTC (permalink / raw) To: Sven Eckelmann; +Cc: b.a.t.m.a.n, Marek Lindner, Greg KH, siwu On 2010-11-10 at 17:46:37 +0100, Sven Eckelmann <sven.eckelmann@gmx.de> wrote: > > compare_ether_addr uses a two byte pointer to access 3x two bytes. This > > makes it necessary to have all those 3 bytes aligned to 2 byte boundaries. > [correction sent later: "6x two bytes aligned to 2 byte boundaries"] > > Otherwise the compiler has to generate special instructions on > > architectures which don't support loads on non-aligned addresses. Usually > > he doesn't do it unless he has some indications that it is necessary > > (__attribute__ ((packed)) for example). > > > > There is also documentation available on that topic in > > Documentation/unaligned-memory-access.txt > > > > And maybe it is good to use is_broadcast_ether_addr, but leave > > compare_ether_addr part open (or prove that we always have those two > > operands correctly aligned). > [...] > > None of that happened yet. And yes, this wasn't the last mail we sent to him > to get some response - no answer till now. I'll send an updated patch, leaving out the compare_ether_addr part. Cheers Tobias ^ permalink raw reply [flat|nested] 8+ messages in thread
[parent not found: <BAY127-W15AD53BC245C1D430CF07BCF360@phx.gbl>]
* Re: [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree [not found] ` <BAY127-W15AD53BC245C1D430CF07BCF360@phx.gbl> @ 2010-11-15 10:21 ` Marek Lindner 0 siblings, 0 replies; 8+ messages in thread From: Marek Lindner @ 2010-11-15 10:21 UTC (permalink / raw) To: Tan Zhi Heng; +Cc: b.a.t.m.a.n, gregkh, siwu Hi, > Hello, im a BATMAN user and also a member of the website. Im doing a > project using BATMAN for MANET.I actually plan to modify codes from > batman-0.3.2, to be able to modify the packet header and send the codes > between notebooks. Any kind soul able to point me in the direction to look > at? Which codes do i specifically modify? you wish to modify the batman daemon sources ? What kind of changes do you have in mind ? Note that HTML mails are not blocked on the batman mailing list. Cheers, Marek ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree 2010-11-11 8:52 ` Tobias Klauser [not found] ` <BAY127-W15AD53BC245C1D430CF07BCF360@phx.gbl> @ 2010-11-17 16:32 ` Marek Lindner 1 sibling, 0 replies; 8+ messages in thread From: Marek Lindner @ 2010-11-17 16:32 UTC (permalink / raw) To: b.a.t.m.a.n; +Cc: Tobias Klauser, Greg KH, siwu Tobias, > I'll send an updated patch, leaving out the compare_ether_addr part. not necessary anymore. Today I included a patch from Sven that does the job. Thanks for bringing this up, Marek ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2010-11-17 16:32 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <12893476522148@site>
2010-11-10 10:17 ` [B.A.T.M.A.N.] patch "staging: batman-adv: Use linux/etherdevice.h address helper functions" added to staging tree Marek Lindner
2010-11-10 16:04 ` Greg KH
2010-11-10 16:46 ` Sven Eckelmann
2010-11-11 1:11 ` Greg KH
2010-11-11 10:34 ` Marek Lindner
2010-11-11 8:52 ` Tobias Klauser
[not found] ` <BAY127-W15AD53BC245C1D430CF07BCF360@phx.gbl>
2010-11-15 10:21 ` Marek Lindner
2010-11-17 16:32 ` Marek Lindner
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox