public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: Adrian Remonda <adrianremonda@gmail.com>
Cc: corbet@lwn.net, linux-spi@vger.kernel.org,
	linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/4] Added input buffer from the terminal.
Date: Mon, 9 Mar 2015 18:38:30 +0000	[thread overview]
Message-ID: <20150309183830.GY28806@sirena.org.uk> (raw)
In-Reply-To: <1425750995-18176-4-git-send-email-adrianremonda@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 396 bytes --]

On Sat, Mar 07, 2015 at 12:56:34PM -0500, Adrian Remonda wrote:

> +	int ret = 0;
> +	char *pSrc = src;

The kernel coding style doesn't use Hungarian notation...

> +	if (input_tx) {
> +		size = strlen(input_tx+1);
> +		tx = (uint8_t *)malloc(size);
> +		rx = (uint8_t *)malloc(size);

You should never need to cast the return value of malloc() - if it's
needed it's masking some other problem.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

  parent reply	other threads:[~2015-03-09 18:38 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-07 17:56 [PATCH 0/4] spi: spidev_test: Added functionalities Adrian Remonda
2015-03-07 17:56 ` [PATCH 1/4] Cleaned hexadecimal dump Adrian Remonda
2015-03-07 17:56   ` [PATCH 2/4] Added verbose output Adrian Remonda
2015-03-07 17:56     ` [PATCH 3/4] Added input buffer from the terminal Adrian Remonda
2015-03-07 17:56       ` [PATCH 4/4] Moved spidev_tools.c to tools/spi Adrian Remonda
2015-03-09 18:38       ` Mark Brown [this message]
2015-03-08  2:22   ` [PATCH 1/4] Cleaned hexadecimal dump Joe Perches
2015-03-08 10:53     ` Andy Shevchenko
2015-03-08 16:20       ` Joe Perches
2015-03-09 13:51   ` Geert Uytterhoeven
2015-03-09 18:40   ` Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150309183830.GY28806@sirena.org.uk \
    --to=broonie@kernel.org \
    --cc=adrianremonda@gmail.com \
    --cc=corbet@lwn.net \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox