Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx> writes: > Hello, > > today I looked at the changes to drivers/net/ethernet/freescale/fec.c in > the kernel since v3.8 using > > git log --stat v3.8.. --full-diff -- drivers/net/ethernet/freescale/fec.c > > which looks as expected. But when I added --graph the diffstats change. > E.g. for 793fc0964be1921f15a44be58b066f22b925d90b it changes from: > > drivers/net/ethernet/freescale/Makefile | 3 +- > drivers/net/ethernet/freescale/fec.c | 1966 ----------------------------- > drivers/net/ethernet/freescale/fec_main.c | 1966 +++++++++++++++++++++++++++++ > drivers/net/ethernet/freescale/fec_ptp.c | 3 - > 4 files changed, 1968 insertions(+), 1970 deletions(-) > > to > > | Documentation/devicetree/bindings/net/dsa/dsa.txt | 91 + > | .../bindings/net/marvell-orion-mdio.txt | 3 + > | Documentation/networking/ip-sysctl.txt | 35 +- [...] > | 404 files changed, 15373 insertions(+), 8563 deletions(-) > > Is that a bug, or a feature I don't understand? Nice catch. It's a bad interaction between --full-diff, --stat and --parents (which --graph implies in an internal-workings kind of way). The parent rewriting gets to mess with the history *before* we generate the diffs. Normally this wouldn't matter, because the pathspec filter would then again exclude all but the "real" change from the diff. But with --full-diff, you see all the changes between 793fc096 and the next commit that touches the given pathspec (47a5247f), which is -- at this stage, after rewriting -- the "parent". I suspect to fix this we'll need to separate the "real" from the "rewritten" parents, which might take a bit of work. -- Thomas Rast trast@{inf,student}.ethz.ch -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html