Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Senna Tschudin <peter.senna@linux.intel.com>
To: "Vivekanandan,
	Balasubramani" <balasubramani.vivekanandan@intel.com>,
	"Cavitt, Jonathan" <jonathan.cavitt@intel.com>,
	"igt-dev@lists.freedesktop.org" <igt-dev@lists.freedesktop.org>
Cc: "Senna, Peter" <peter.senna@intel.com>,
	"Gandi, Ramadevi" <ramadevi.gandi@intel.com>,
	"Knop, Ryszard" <ryszard.knop@intel.com>,
	"Lattannavar, Sameer" <sameer.lattannavar@intel.com>,
	"De Marchi, Lucas" <lucas.demarchi@intel.com>,
	"Saarinen, Jani" <jani.saarinen@intel.com>,
	"Piecielska, Katarzyna" <katarzyna.piecielska@intel.com>,
	"Roper, Matthew D" <matthew.d.roper@intel.com>,
	"gregory.f.germano@intel.com" <gregory.f.germano@intel.com>,
	"Taylor, Clinton A" <clinton.a.taylor@intel.com>,
	"Yu, Jianshui" <jianshui.yu@intel.com>
Subject: Re: [PATCH RFC i-g-t] lib/igt_kmemleak: library to interact with kmemleak
Date: Thu, 9 Jan 2025 19:21:45 +0100	[thread overview]
Message-ID: <e496929e-b3c0-4167-b17e-59138757fbb7@linux.intel.com> (raw)
In-Reply-To: <Z34Lz0Zd4X_mfGHf@bvivekan-mobl1>

Dear Bala,

Thank you for your review!

[...]

>>> +static void test_igt_kmemleak_cp_leaks_file(void)
>>> +{
>>> +	char dst_file_path[256] = "/tmp/igt_kmemleak_dstfile_XXXXXX";
>>> +	int fd;
>>> +	unsigned long crc;
>>> +
>>> +	fd = mkstemp(dst_file_path);
>>> +	close(fd);
>>> +
>>> +	igt_assert(igt_kmemleak_cp_leaks_file(dst_file_path));
>>> +
>>> +	/* Test that both files have the same size */
>>> +	fd = open(dst_file_path, O_RDONLY);
>>> +	igt_assert(fd >= 0);
>>> +	igt_assert(lseek(fd, 0, SEEK_END) == strlen(kmemleak_file_example));
>>> +	close(fd);
>>> +
>>> +	/* Test that both files have the same content */
>>> +	crc = crc32(0, Z_NULL, 0);
>>> +	crc = crc32(crc,
>>> +		    (const Bytef *)kmemleak_file_example,
>>> +		    strlen(kmemleak_file_example));
> 
> Did you miss the changes to compare the CRC?

Not only that, but I did not use crc32_file()... Thank you for catching this!
Fixed on V1.

> 
> Regards,
> Bala
> 

[...]

  reply	other threads:[~2025-01-09 18:21 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-16 18:46 [PATCH RFC i-g-t] lib/igt_kmemleak: library to interact with kmemleak Peter Senna Tschudin
2024-12-16 22:59 ` ✗ GitLab.Pipeline: warning for " Patchwork
2024-12-16 23:26 ` ✗ i915.CI.BAT: failure " Patchwork
2024-12-17  1:29 ` ✓ Xe.CI.BAT: success " Patchwork
2024-12-17  7:35 ` ✗ Xe.CI.Full: failure " Patchwork
2025-01-07 20:17 ` [PATCH RFC i-g-t] " Cavitt, Jonathan
2025-01-08  5:23   ` Vivekanandan, Balasubramani
2025-01-09 18:21     ` Peter Senna Tschudin [this message]
2025-01-09 18:18   ` Peter Senna Tschudin

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=e496929e-b3c0-4167-b17e-59138757fbb7@linux.intel.com \
    --to=peter.senna@linux.intel.com \
    --cc=balasubramani.vivekanandan@intel.com \
    --cc=clinton.a.taylor@intel.com \
    --cc=gregory.f.germano@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=jani.saarinen@intel.com \
    --cc=jianshui.yu@intel.com \
    --cc=jonathan.cavitt@intel.com \
    --cc=katarzyna.piecielska@intel.com \
    --cc=lucas.demarchi@intel.com \
    --cc=matthew.d.roper@intel.com \
    --cc=peter.senna@intel.com \
    --cc=ramadevi.gandi@intel.com \
    --cc=ryszard.knop@intel.com \
    --cc=sameer.lattannavar@intel.com \
    /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