mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: Takashi Sakamoto <o-takashi@sakamocchi.jp>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linux Next Mailing List <linux-next@vger.kernel.org>
Subject: linux-next: manual merge of the ieee1394 tree with the origin tree
Date: Mon, 19 Oct 2026 17:10:56 +0100	[thread overview]
Message-ID: <atZBEI6G3PgKHKaW@sirena.co.uk> (raw)

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

Hi all,

Today's linux-next merge of the ieee1394 tree got a conflict in:

  drivers/firewire/core-transaction.c

between commit:

  7f9f2d6abc40f ("firewire: core: fix race condition in split transaction handling")

from the origin tree and commit:

  0f7228de31f1c ("firewire: core: expand close_transaction() into its callers and remove it")

from the ieee1394 tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

diff --cc drivers/firewire/core-transaction.c
index 016070560c742,a0379fc3e60e5..0000000000000
--- a/drivers/firewire/core-transaction.c
+++ b/drivers/firewire/core-transaction.c
@@@ -89,53 -94,28 +94,32 @@@ void fw_cancel_pending_transactions(str
  			break;						\
  		}							\
  	}								\
- 	if (t) {							\
- 		if (try_cancel_split_timeout(t))			\
- 			remove_transaction_entry(card, t);		\
 -	if (__t && try_cancel_split_timeout(__t))			\
 -		remove_transaction_entry(card, __t);			\
++	if (__t) {							\
++		if (try_cancel_split_timeout(__t))			\
++			remove_transaction_entry(card, __t);		\
 +		else							\
- 			t = NULL;					\
++			__t = NULL;					\
 +	}								\
- 	t;								\
+ 	__t;								\
  })
  
- static int close_transaction(struct fw_transaction *transaction, struct fw_card *card, int rcode,
- 			     u32 response_tstamp)
- {
- 	struct fw_transaction *t;
- 
- 	// NOTE: This can be without irqsave when we can guarantee that __fw_send_request() for
- 	// local destination never runs in any type of IRQ context.
- 	scoped_guard(spinlock_irqsave, &card->transactions.lock) {
- 		t = find_and_pop_transaction_entry(card, iter == transaction);
- 		if (!t)
- 			return -ENOENT;
- 	}
- 
- 	if (!t->with_tstamp) {
- 		t->callback.without_tstamp(card, rcode, NULL, 0, t->callback_data);
- 	} else {
- 		t->callback.with_tstamp(card, rcode, t->packet.timestamp, response_tstamp, NULL, 0,
- 					t->callback_data);
- 	}
- 
- 	return 0;
- }
- 
- /*
-  * Only valid for transactions that are potentially pending (ie have
-  * been sent).
+ /**
+  * fw_cancel_transaction: cancel transaction.
+  * @card:		interface where the transaction has been requested
+  * @transaction:	transaction instance to be cancelled
+  *
+  * Terminate the transaction by either canceling the request subaction or the response subaction
+  * of the split transaction, then schedule the transaction callback to notify the cancellation.
+  * The transaction instance should be kept until the callback will be invoked.
+  *
+  * Context: Process context.
+  * Returns: 0 on success, -ENOENT if the transaction instance is not found in the queue for the
+  * pending transaction.
   */
- int fw_cancel_transaction(struct fw_card *card,
- 			  struct fw_transaction *transaction)
+ int fw_cancel_transaction(struct fw_card *card, struct fw_transaction *transaction)
  {
- 	u32 tstamp;
- 
- 	/*
- 	 * Cancel the packet transmission if it's still queued.  That
- 	 * will call the packet transmission callback which cancels
- 	 * the transaction.
- 	 */
- 
+ 	// Cancel the packet transmission if it's still queued. That will schedule the packet
+ 	// transmission callback which cancels the transaction.
  	if (card->driver->cancel_packet(card, &transaction->packet) == 0)
  		return 0;
  

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

             reply	other threads:[~2026-10-19 16:10 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-19 16:10 Mark Brown [this message]
2026-10-20  1:44 ` Takashi Sakamoto

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=atZBEI6G3PgKHKaW@sirena.co.uk \
    --to=broonie@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=o-takashi@sakamocchi.jp \
    /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

all inboxes | Powered by JetHome®