[libcamera-devel] [PATCH] Fix incorrect method in cameradata docs

Laurent Pinchart laurent.pinchart at ideasonboard.com
Tue Jun 16 04:49:43 CEST 2020


On Mon, Jun 15, 2020 at 03:14:26PM +0000, Umang Jain wrote:
> On 6/15/20 8:19 PM, chris at gregariousmammal.com wrote:

We try to always include a commit message, even for simple changes. It's
not a hard requirements, but it's highly encouraged.

> > From: Chris Chinchilla <chris at gregariousmammal.com>
> >
> > ---
> >   src/libcamera/pipeline_handler.cpp | 2 +-
> >   1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/src/libcamera/pipeline_handler.cpp b/src/libcamera/pipeline_handler.cpp
> > index a0f6b0f..fca11cb 100644
> > --- a/src/libcamera/pipeline_handler.cpp
> > +++ b/src/libcamera/pipeline_handler.cpp
> > @@ -46,7 +46,7 @@ LOG_DEFINE_CATEGORY(Pipeline)
> >    *
> >    * Pipeline handlers are expected to extend this base class with platform
> >    * specific implementation, associate instances of the derived classes
> > - * using the setCameraData() method, and access them at a later time
> > + * using the registerCamera() method, and access them at a later time
> >    * with cameraData().
> >    */
> 
> The change looks good. :-)
> 
> Couple of comments on the commit message.
> 
> * Missing sign-off tag
> 
>     - Patches need to signed off. You can use --signoff flag while 
> committing (git commit --signoff ...)

Or -s, that's shorter. And we even document the Signed-off-by
requirement in http://libcamera.org/contributing.html#submitting-patches
:-)

> 
> * Missing "Fixes:" tag
>     - This commit actually fixes commit: b581b9576abd ("libcamera: 
> pipeline_handler: Make pipeline-specific data mandatory"), so add this 
> tag to the commit message:
> 
> Fixes: b581b9576abd ("libcamera: pipeline_handler: Make pipeline-specific data mandatory")

To add a bit more information, 'git blame' can help checking which
commit last modified a given line. To generate the Fixes: line, I have
added the following in ~/.gitconfig:

[pretty]
	fixes = Fixes: %h (\"%s\")

and added the following function in my ~.bashrc:

gpf() {
	git show --pretty=fixes ${1:-HEAD} | head -1
}

Running

gpf b581b9576abd

produces

Fixes: b581b9576abd ("libcamera: pipeline_handler: Make pipeline-specific data mandatory")

> Once you have these two things in your commit message:
> 
> Reviewed-by: Umang Jain <email at uajain.com>

Same,

Reviewed-by: Laurent Pinchart <laurent.pinchart at ideasonboard.com>

-- 
Regards,

Laurent Pinchart


More information about the libcamera-devel mailing list