From: Masahiro Yamada Date: Mon, 23 Jun 2014 12:51:13 +0900 Subject: [U-Boot] [PATCH] patman: Only apply patches when we know the original HEAD In-Reply-To: References: <20140623121919.9343.AA925319@jp.panasonic.com> Message-ID: <20140623125113.9347.AA925319@jp.panasonic.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Simon, On Sun, 22 Jun 2014 21:39:26 -0600 Simon Glass wrote: > Hi Masahiro, > > On 22 June 2014 21:19, Masahiro Yamada wrote: > > Hi Simon, > > > > > > On Sat, 21 Jun 2014 10:27:06 -0600 > > Simon Glass wrote: > > > >> Hi Masahiro, > >> > >> On 11 June 2014 23:27, Simon Glass wrote: > >> > When patman applies the patches it checks out a new branch, uses 'git am' > >> > to apply the patches one by one, and then tries to go back to the old > >> > branch. If you try this when the branch is 'undefined', this doesn't work > >> > as patman cannot restore the correct branch after applying the patches. > >> > It seems that 'undefined' is created by git and is persistent after it is > >> > created, so that you can end up on quite an old branch. > >> > > >> > Add a check for the 'undefined' branch to avoid this. > >> > > >> > Reported-by: Masahiro Yamada > >> > Signed-off-by: Simon Glass > >> > >> Can you please check if this fixes the problem you reported? If so I > >> would like to get it into this release. > > > > > > I cannot understand why patman needs to apply the patches with 'git am'. > > > > Why isn't patman like this ? > > [1] Generate patches with 'git format-patch' > > [2] Parse the patman-tags in the generated patches and edit them. > > 2a. Apply the patches to make sure there are no whitespace errors. > > > [3] Send the patches with 'git send-email' > > > > The whitespace problems are not common but they do happen sometimes - > or at least I have seen it at times. Unless perhaps checkpatch has got > smarter? I still don't understand. Anyway, Patman invokes checkpatch.pl, right? Isn't whitespace error checking of checkpatch nice? Best Regards Masahiro Yamada