Re: [PATCH for 4.16 04/10] membarrier: provide SHARED_EXPEDITED command (v2)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 16 Jan 2018, Mathieu Desnoyers wrote:
> ----- On Jan 16, 2018, at 1:20 PM, Thomas Gleixner tglx@xxxxxxxxxxxxx wrote:
> > And I really have to ask whether this should be named _GLOBAL_ instead of
> > _SHARED_.
> > 
> > Hmm?
> 
> I agree with you that this behavior fits better a "global" definition
> than a "shared" one, especially given that it does not target a specific
> shared memory mapping. The main issue I have is due to the pre-existing
> MEMBARRIER_CMD_SHARED introduced in Linux 4.3. That one should also have
> been called "MEMBARRIER_CMD_GLOBAL" based on the current line of thoughts.
> 
> Do you envision a way to transition forward to a new "MEMBARRIER_CMD_GLOBAL" for
> the currently existing MEMBARRIER_CMD_SHARED ?
> 
> Perhaps with a duplicated enum entry ?
> 
> enum membarrier_cmd {
>         MEMBARRIER_CMD_QUERY                                    = 0,
>         MEMBARRIER_CMD_SHARED                                   = (1 << 0), /* use MEMBARRIER_CMD_GLOBAL instead */
>         MEMBARRIER_CMD_GLOBAL                                   = (1 << 0),

That should work. Though I doubt that you ever can get rid of CMD_SHARED,
but at least the code is clearer that way.

Thanks,

	tglx
--
To unsubscribe from this list: send the line "unsubscribe linux-api" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux