Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/254/?format=api
{ "id": 254, "url": "http://patchwork.ozlabs.org/api/patches/254/?format=api", "web_url": "http://patchwork.ozlabs.org/project/cbe-oss-dev/patch/200809112038.17055.adetsch@br.ibm.com/", "project": { "id": 1, "url": "http://patchwork.ozlabs.org/api/projects/1/?format=api", "name": "Cell Broadband Engine development", "link_name": "cbe-oss-dev", "list_id": "cbe-oss-dev.ozlabs.org", "list_email": "cbe-oss-dev@ozlabs.org", "web_url": null, "scm_url": null, "webscm_url": null, "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<200809112038.17055.adetsch@br.ibm.com>", "list_archive_url": null, "date": "2008-09-11T23:38:16", "name": "powerpc/spufs: Allow gang to grow in size after it has been started", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": false, "hash": "c6dec257a59df2be4ab7d4ead15d4cc8c20ae99f", "submitter": { "id": 93, "url": "http://patchwork.ozlabs.org/api/people/93/?format=api", "name": "Andre Detsch", "email": "adetsch@br.ibm.com" }, "delegate": { "id": 1, "url": "http://patchwork.ozlabs.org/api/users/1/?format=api", "username": "jk", "first_name": "Jeremy", "last_name": "Kerr", "email": "jk@ozlabs.org" }, "mbox": "http://patchwork.ozlabs.org/project/cbe-oss-dev/patch/200809112038.17055.adetsch@br.ibm.com/mbox/", "series": [], "comments": "http://patchwork.ozlabs.org/api/patches/254/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/254/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<cbe-oss-dev-bounces+patchwork=ozlabs.org@ozlabs.org>", "X-Original-To": [ "patchwork@ozlabs.org", "cbe-oss-dev@ozlabs.org" ], "Delivered-To": [ "patchwork@ozlabs.org", "cbe-oss-dev@ozlabs.org" ], "Received": [ "from ozlabs.org (localhost [127.0.0.1])\n\tby ozlabs.org (Postfix) with ESMTP id EBB59DE764\n\tfor <patchwork@ozlabs.org>; Fri, 12 Sep 2008 09:40:10 +1000 (EST)", "from igw2.br.ibm.com (igw2.br.ibm.com [32.104.18.25])\n\t(using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))\n\t(Client CN \"mailgw2.br.ibm.com\", Issuer \"Equifax\" (not verified))\n\tby ozlabs.org (Postfix) with ESMTPS id 5C5F7DE023;\n\tFri, 12 Sep 2008 09:39:09 +1000 (EST)", "from mailhub1.br.ibm.com (mailhub1 [9.18.232.109])\n\tby igw2.br.ibm.com (Postfix) with ESMTP id AE61B17F4F6;\n\tThu, 11 Sep 2008 20:23:47 -0300 (BRT)", "from d24av01.br.ibm.com (d24av01.br.ibm.com [9.18.232.46])\n\tby mailhub1.br.ibm.com (8.13.8/8.13.8/NCO v9.1) with ESMTP id\n\tm8BNd4HT1855914; Thu, 11 Sep 2008 20:39:04 -0300", "from d24av01.br.ibm.com (loopback [127.0.0.1])\n\tby d24av01.br.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id\n\tm8BNcwau024323; Thu, 11 Sep 2008 20:38:58 -0300", "from [9.8.10.86] ([9.8.10.86])\n\tby d24av01.br.ibm.com (8.12.11.20060308/8.12.11) with ESMTP id\n\tm8BNcwEx024320; Thu, 11 Sep 2008 20:38:58 -0300" ], "From": "Andre Detsch <adetsch@br.ibm.com>", "To": "cbe-oss-dev@ozlabs.org", "Date": "Thu, 11 Sep 2008 20:38:16 -0300", "User-Agent": "KMail/1.9.6", "References": "<200809111955.28780.adetsch@br.ibm.com>", "In-Reply-To": "<200809111955.28780.adetsch@br.ibm.com>", "MIME-Version": "1.0", "Content-Disposition": "inline", "Message-Id": "<200809112038.17055.adetsch@br.ibm.com>", "Cc": "LukeBrowning@us.ibm.com, Jeremy Kerr <jk@ozlabs.org>", "Subject": "[Cbe-oss-dev] [PATCH 07/11] powerpc/spufs: Allow gang to grow in\n\tsize after it has been started", "X-BeenThere": "cbe-oss-dev@ozlabs.org", "X-Mailman-Version": "2.1.11", "Precedence": "list", "List-Id": "Discussion about Open Source Software for the Cell Broadband Engine\n\t<cbe-oss-dev.ozlabs.org>", "List-Unsubscribe": "<https://ozlabs.org/mailman/options/cbe-oss-dev>,\n\t<mailto:cbe-oss-dev-request@ozlabs.org?subject=unsubscribe>", "List-Archive": "<http://ozlabs.org/pipermail/cbe-oss-dev>", "List-Post": "<mailto:cbe-oss-dev@ozlabs.org>", "List-Help": "<mailto:cbe-oss-dev-request@ozlabs.org?subject=help>", "List-Subscribe": "<https://ozlabs.org/mailman/listinfo/cbe-oss-dev>,\n\t<mailto:cbe-oss-dev-request@ozlabs.org?subject=subscribe>", "Content-Type": "text/plain; charset=\"us-ascii\"", "Content-Transfer-Encoding": "7bit", "Sender": "cbe-oss-dev-bounces+patchwork=ozlabs.org@ozlabs.org", "Errors-To": "cbe-oss-dev-bounces+patchwork=ozlabs.org@ozlabs.org" }, "content": "Just deactivate it, add the new context, and let the calling thread\ndrives its reactivation. It needs to be unscheduled, since it may\nno longer fit or it may need to be migrated to a different node.\n\nSigned-off-by: Luke Browning <lukebrowning@us.ibm.com>\nSigned-off-by: Andre Detsch <adetsch@br.ibm.com>", "diff": "diff --git a/arch/powerpc/platforms/cell/spufs/context.c \nb/arch/powerpc/platforms/cell/spufs/context.c\nindex 21ba409..c472519 100644\n--- a/arch/powerpc/platforms/cell/spufs/context.c\n+++ b/arch/powerpc/platforms/cell/spufs/context.c\n@@ -57,6 +57,17 @@ struct spu_context *alloc_spu_context(struct spu_gang \n*gang)\n \tif (spu_init_csa(&ctx->csa))\n \t\tgoto out_free_gang;\n \n+\t/* If the gang is running, it needs to be stopped, since we have a\n+\t * new context that needs to be gang scheduled. Gangs are allowed\n+\t * to grow and shrink over time, but they are unscheduled when it\n+\t * happens as the gang may need to migrated to a different node.\n+\t */\n+\tif (atomic_read(&gang->nstarted)) {\n+\t\tmutex_lock(&gang->mutex);\n+\t\tspu_deactivate(gang);\n+\t\tmutex_unlock(&gang->mutex);\n+\t}\n+\n \tspin_lock_init(&ctx->mmio_lock);\n \tmutex_init(&ctx->mapping_lock);\n", "prefixes": [] }