Frederik Bayart wrote: > Hallo, > > I reported this problem already on March, but I don't find my mail in the > archives, so I report it again. > > I found a bug in e1000_main.c, in function e1000_probe : > > adapter->bd_number = cards_found > > should be : > > adapter->bd_number = cards_found -1 > > because cards_found was incremented at the start of the function : > > if (cards[cards_found++] == 0) > { > return -ENODEV; > } > > This has as consequence dat the parameters are initialized incorrect, e.g. > if in rtnet.conf > > RT_DRIVER_OPTIONS="cards=0,1,0 and RxIntDelay=0,1,2" > > the parameter will be > initialized with 2 instead of 1 for the 2nd card. > > Below you find the output from git diff > > Frederik (frederik.bay...@triphase.com) > > diff --git a/drivers/e1000/e1000_main.c b/drivers/e1000/e1000_main.c > index 27c85c3..12a8ef3 100644 > --- a/drivers/e1000/e1000_main.c > +++ b/drivers/e1000/e1000_main.c > @@ -779,7 +779,7 @@ e1000_probe(struct pci_dev *pdev, > netdev->mem_end = mmio_start + mmio_len; > netdev->base_addr = adapter->hw.io_base; > > - adapter->bd_number = cards_found; > + adapter->bd_number = cards_found - 1; > > /* setup the private structure */ >
Thanks, good catch. But let me explain (also for everyone else interested in sending patches) how you could produce the preferred patch format: 1. Commit your change(s) to you local git repository (e.g. via 'git commit -s -a' which commits all changes). You will be asked for a commit comment, please provide a precise summary of the above. 2. Use 'git format-patch HEAD^..HEAD' to extract the patch in right format and copy&paste it into your mail client (there are also other ways like 'git send-email', but the latter is more transparent for starters). Please give this a try and I will happily apply the result. Thanks again, Jan
signature.asc
Description: OpenPGP digital signature
------------------------------------------------------------------------------
_______________________________________________ RTnet-users mailing list RTnet-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rtnet-users