<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git/include/linux/genalloc.h, branch v4.12.4</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.12.4</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.12.4'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2015-12-22T23:10:17Z</updated>
<entry>
<title>genalloc:support allocating specific region</title>
<updated>2015-12-22T23:10:17Z</updated>
<author>
<name>Zhao Qiang</name>
<email>qiang.zhao@freescale.com</email>
</author>
<published>2015-11-30T02:48:53Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=b26981c8f743d3cb64a6907eb1f5c6c4ba6ca672'/>
<id>urn:sha1:b26981c8f743d3cb64a6907eb1f5c6c4ba6ca672</id>
<content type='text'>
Add new algo for genalloc, it reserve a specific region of
memory

Signed-off-by: Zhao Qiang &lt;qiang.zhao@freescale.com&gt;
Signed-off-by: Scott Wood &lt;scottwood@freescale.com&gt;
</content>
</entry>
<entry>
<title>genalloc:support memory-allocation with bytes-alignment to genalloc</title>
<updated>2015-12-22T23:10:17Z</updated>
<author>
<name>Zhao Qiang</name>
<email>qiang.zhao@freescale.com</email>
</author>
<published>2015-11-30T02:48:52Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=de2dd0eb30af55d3893979d5641c50c7a8969c99'/>
<id>urn:sha1:de2dd0eb30af55d3893979d5641c50c7a8969c99</id>
<content type='text'>
Bytes alignment is required to manage some special RAM,
so add gen_pool_first_fit_align to genalloc,
meanwhile add gen_pool_alloc_algo to pass algo in case user
layer using more than one algo, and pass data to
gen_pool_first_fit_align(modify gen_pool_alloc as a wrapper)

Signed-off-by: Zhao Qiang &lt;qiang.zhao@freescale.com&gt;
Signed-off-by: Scott Wood &lt;scottwood@freescale.com&gt;
</content>
</entry>
<entry>
<title>genalloc: add support of multiple gen_pools per device</title>
<updated>2015-09-04T23:54:41Z</updated>
<author>
<name>Vladimir Zapolskiy</name>
<email>vladimir_zapolskiy@mentor.com</email>
</author>
<published>2015-09-04T22:47:47Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=c98c36355dd6d5c4433c8d17e8eb839ca9b97606'/>
<id>urn:sha1:c98c36355dd6d5c4433c8d17e8eb839ca9b97606</id>
<content type='text'>
This change fills devm_gen_pool_create()/gen_pool_get() "name" argument
stub with contents and extends of_gen_pool_get() functionality on this
basis.

If there is no associated platform device with a device node passed to
of_gen_pool_get(), the function attempts to get a label property or device
node name (= repeats MTD OF partition standard) and seeks for a named
gen_pool registered by device of the parent device node.

The main idea of the change is to allow registration of independent
gen_pools under the same umbrella device, say "partitions" on "storage
device", the original functionality of one "partition" per "storage
device" is untouched.

[akpm@linux-foundation.org: fix constness in devres_find()]
[dan.carpenter@oracle.com: freeing const data pointers]
Signed-off-by: Vladimir Zapolskiy &lt;vladimir_zapolskiy@mentor.com&gt;
Cc: Philipp Zabel &lt;p.zabel@pengutronix.de&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Cc: Russell King &lt;linux@arm.linux.org.uk&gt;
Cc: Nicolas Ferre &lt;nicolas.ferre@atmel.com&gt;
Cc: Alexandre Belloni &lt;alexandre.belloni@free-electrons.com&gt;
Cc: Jean-Christophe Plagniol-Villard &lt;plagnioj@jcrosoft.com&gt;
Cc: Shawn Guo &lt;shawnguo@kernel.org&gt;
Cc: Sascha Hauer &lt;kernel@pengutronix.de&gt;
Cc: Mauro Carvalho Chehab &lt;mchehab@osg.samsung.com&gt;
Cc: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>genalloc: add name arg to gen_pool_get() and devm_gen_pool_create()</title>
<updated>2015-09-04T23:54:41Z</updated>
<author>
<name>Vladimir Zapolskiy</name>
<email>vladimir_zapolskiy@mentor.com</email>
</author>
<published>2015-09-04T22:47:43Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=73858173593c31cb94bce63fe1c24eb803bb04e6'/>
<id>urn:sha1:73858173593c31cb94bce63fe1c24eb803bb04e6</id>
<content type='text'>
This change modifies gen_pool_get() and devm_gen_pool_create() client
interfaces adding one more argument "name" of a gen_pool object.

Due to implementation gen_pool_get() is capable to retrieve only one
gen_pool associated with a device even if multiple gen_pools are created,
fortunately right at the moment it is sufficient for the clients, hence
provide NULL as a valid argument on both producer devm_gen_pool_create()
and consumer gen_pool_get() sides.

Because only one created gen_pool per device is addressable, explicitly
add a restriction to devm_gen_pool_create() to create only one gen_pool
per device, this implies two possible error codes returned by the
function, account it on client side (only misc/sram).  This completes
client side changes related to genalloc updates.

[akpm@linux-foundation.org: gen_pool_get() cleanup]
Signed-off-by: Vladimir Zapolskiy &lt;vladimir_zapolskiy@mentor.com&gt;
Cc: Philipp Zabel &lt;p.zabel@pengutronix.de&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Cc: Russell King &lt;linux@arm.linux.org.uk&gt;
Cc: Nicolas Ferre &lt;nicolas.ferre@atmel.com&gt;
Cc: Alexandre Belloni &lt;alexandre.belloni@free-electrons.com&gt;
Cc: Jean-Christophe Plagniol-Villard &lt;plagnioj@jcrosoft.com&gt;
Cc: Shawn Guo &lt;shawnguo@kernel.org&gt;
Cc: Sascha Hauer &lt;kernel@pengutronix.de&gt;
Cc: Mauro Carvalho Chehab &lt;mchehab@osg.samsung.com&gt;
Cc: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>genalloc: rename of_get_named_gen_pool() to of_gen_pool_get()</title>
<updated>2015-07-01T02:45:01Z</updated>
<author>
<name>Vladimir Zapolskiy</name>
<email>vladimir_zapolskiy@mentor.com</email>
</author>
<published>2015-06-30T22:00:07Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=abdd4a7025282fbe3737e1bcb5f51afc8d8ea1b8'/>
<id>urn:sha1:abdd4a7025282fbe3737e1bcb5f51afc8d8ea1b8</id>
<content type='text'>
To be consistent with other kernel interface namings, rename
of_get_named_gen_pool() to of_gen_pool_get().  In the original function
name "_named" suffix references to a device tree property, which contains
a phandle to a device and the corresponding device driver is assumed to
register a gen_pool object.

Due to a weak relation and to avoid any confusion (e.g.  in future
possible scenario if gen_pool objects are named) the suffix is removed.

[sfr@canb.auug.org.au: crypto/marvell/cesa - fix up for of_get_named_gen_pool() rename]
Signed-off-by: Vladimir Zapolskiy &lt;vladimir_zapolskiy@mentor.com&gt;
Cc: Nicolas Ferre &lt;nicolas.ferre@atmel.com&gt;
Cc: Philipp Zabel &lt;p.zabel@pengutronix.de&gt;
Cc: Shawn Guo &lt;shawn.guo@linaro.org&gt;
Cc: Sascha Hauer &lt;kernel@pengutronix.de&gt;
Cc: Alexandre Belloni &lt;alexandre.belloni@free-electrons.com&gt;
Cc: Russell King &lt;linux@arm.linux.org.uk&gt;
Cc: Mauro Carvalho Chehab &lt;mchehab@osg.samsung.com&gt;
Cc: Vinod Koul &lt;vinod.koul@intel.com&gt;
Cc: Takashi Iwai &lt;tiwai@suse.de&gt;
Cc: Jaroslav Kysela &lt;perex@perex.cz&gt;
Signed-off-by: Stephen Rothwell &lt;sfr@canb.auug.org.au&gt;
Cc: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
Cc: Boris BREZILLON &lt;boris.brezillon@free-electrons.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>genalloc: rename dev_get_gen_pool() to gen_pool_get()</title>
<updated>2015-07-01T02:45:01Z</updated>
<author>
<name>Vladimir Zapolskiy</name>
<email>vladimir_zapolskiy@mentor.com</email>
</author>
<published>2015-06-30T22:00:03Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=0030edf296db8a7afb13573eb12977b7d399cd40'/>
<id>urn:sha1:0030edf296db8a7afb13573eb12977b7d399cd40</id>
<content type='text'>
To be consistent with other genalloc interface namings, rename
dev_get_gen_pool() to gen_pool_get().  The original omitted "dev_" prefix
is removed, since it points to argument type of the function, and so it
does not bring any useful information.

[akpm@linux-foundation.org: update arch/arm/mach-socfpga/pm.c]
Signed-off-by: Vladimir Zapolskiy &lt;vladimir_zapolskiy@mentor.com&gt;
Acked-by: Nicolas Ferre &lt;nicolas.ferre@atmel.com&gt;
Cc: Philipp Zabel &lt;p.zabel@pengutronix.de&gt;
Cc: Shawn Guo &lt;shawn.guo@linaro.org&gt;
Cc: Sascha Hauer &lt;kernel@pengutronix.de&gt;
Cc: Alexandre Belloni &lt;alexandre.belloni@free-electrons.com&gt;
Cc: Russell King &lt;linux@arm.linux.org.uk&gt;
Cc: Mauro Carvalho Chehab &lt;mchehab@osg.samsung.com&gt;
Cc: Vinod Koul &lt;vinod.koul@intel.com&gt;
Cc: Takashi Iwai &lt;tiwai@suse.de&gt;
Cc: Jaroslav Kysela &lt;perex@perex.cz&gt;
Cc: Mark Brown &lt;broonie@kernel.org&gt;
Cc: Nicolas Ferre &lt;nicolas.ferre@atmel.com&gt;
Cc: Alan Tull &lt;atull@opensource.altera.com&gt;
Cc: Dinh Nguyen &lt;dinguyen@opensource.altera.com&gt;
Cc: Kevin Hilman &lt;khilman@linaro.org&gt;
Cc: Stephen Rothwell &lt;sfr@canb.auug.org.au&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>lib/genalloc.c: add genpool range check function</title>
<updated>2014-10-10T02:25:52Z</updated>
<author>
<name>Laura Abbott</name>
<email>lauraa@codeaurora.org</email>
</author>
<published>2014-10-09T22:26:38Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=9efb3a421d55d30b65fb0dbee05108d15c6c55f7'/>
<id>urn:sha1:9efb3a421d55d30b65fb0dbee05108d15c6c55f7</id>
<content type='text'>
After allocating an address from a particular genpool, there is no good
way to verify if that address actually belongs to a genpool.  Introduce
addr_in_gen_pool which will return if an address plus size falls
completely within the genpool range.

Signed-off-by: Laura Abbott &lt;lauraa@codeaurora.org&gt;
Acked-by: Will Deacon &lt;will.deacon@arm.com&gt;
Reviewed-by: Olof Johansson &lt;olof@lixom.net&gt;
Reviewed-by: Catalin Marinas &lt;catalin.marinas@arm.com&gt;
Cc: Arnd Bergmann &lt;arnd@arndb.de&gt;
Cc: David Riley &lt;davidriley@chromium.org&gt;
Cc: Ritesh Harjain &lt;ritesh.harjani@gmail.com&gt;
Cc: Russell King &lt;linux@arm.linux.org.uk&gt;
Cc: Thierry Reding &lt;thierry.reding@gmail.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>lib/genalloc.c: add power aligned algorithm</title>
<updated>2014-10-10T02:25:52Z</updated>
<author>
<name>Laura Abbott</name>
<email>lauraa@codeaurora.org</email>
</author>
<published>2014-10-09T22:26:35Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=505e3be6c082489a32a88e042f930d047b6415bc'/>
<id>urn:sha1:505e3be6c082489a32a88e042f930d047b6415bc</id>
<content type='text'>
One of the more common algorithms used for allocation is to align the
start address of the allocation to the order of size requested.  Add this
as an algorithm option for genalloc.

Signed-off-by: Laura Abbott &lt;lauraa@codeaurora.org&gt;
Acked-by: Will Deacon &lt;will.deacon@arm.com&gt;
Acked-by: Olof Johansson &lt;olof@lixom.net&gt;
Reviewed-by: Catalin Marinas &lt;catalin.marinas@arm.com&gt;
Cc: Arnd Bergmann &lt;arnd@arndb.de&gt;
Cc: David Riley &lt;davidriley@chromium.org&gt;
Cc: Ritesh Harjain &lt;ritesh.harjani@gmail.com&gt;
Cc: Russell King &lt;linux@arm.linux.org.uk&gt;
Cc: Thierry Reding &lt;thierry.reding@gmail.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>include/linux/genalloc.h: spinlock_t needs spinlock_types.h</title>
<updated>2014-01-24T00:36:52Z</updated>
<author>
<name>Shawn Guo</name>
<email>shawn.guo@linaro.org</email>
</author>
<published>2014-01-23T23:53:18Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=b30afea019a4548ee77b73e83f03104e0e3a0556'/>
<id>urn:sha1:b30afea019a4548ee77b73e83f03104e0e3a0556</id>
<content type='text'>
Compiling a C file which includes genalloc.h but without
spinlock_types.h being included before, we will see the compile error
below.

 include/linux/genalloc.h:54:2: error: unknown type name `spinlock_t'

Include spinlock_types.h from genalloc.h to fix the problem.

Signed-off-by: Shawn Guo &lt;shawn.guo@linaro.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>lib/genalloc: add a helper function for DMA buffer allocation</title>
<updated>2013-11-13T03:09:22Z</updated>
<author>
<name>Nicolin Chen</name>
<email>b42378@freescale.com</email>
</author>
<published>2013-11-12T23:09:52Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=684f0d3d14f2744ae7ad79063b21909e32bf444e'/>
<id>urn:sha1:684f0d3d14f2744ae7ad79063b21909e32bf444e</id>
<content type='text'>
When using pool space for DMA buffer, there might be duplicated calling of
gen_pool_alloc() and gen_pool_virt_to_phys() in each implementation.

Thus it's better to add a simple helper function, a compatible one to the
common dma_alloc_coherent(), to save some code.

Signed-off-by: Nicolin Chen &lt;b42378@freescale.com&gt;
Cc: "Hans J. Koch" &lt;hjk@hansjkoch.de&gt;
Cc: Dan Williams &lt;dan.j.williams@intel.com&gt;
Cc: Eric Miao &lt;eric.y.miao@gmail.com&gt;
Cc: Grant Likely &lt;grant.likely@linaro.org&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Cc: Haojian Zhuang &lt;haojian.zhuang@gmail.com&gt;
Cc: Jaroslav Kysela &lt;perex@perex.cz&gt;
Cc: Kevin Hilman &lt;khilman@deeprootsystems.com&gt;
Cc: Liam Girdwood &lt;lgirdwood@gmail.com&gt;
Cc: Mark Brown &lt;broonie@kernel.org&gt;
Cc: Mauro Carvalho Chehab &lt;m.chehab@samsung.com&gt;
Cc: Rob Herring &lt;rob.herring@calxeda.com&gt;
Cc: Russell King &lt;linux@arm.linux.org.uk&gt;
Cc: Sekhar Nori &lt;nsekhar@ti.com&gt;
Cc: Takashi Iwai &lt;tiwai@suse.de&gt;
Cc: Vinod Koul &lt;vinod.koul@intel.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
</feed>
