The locus of $y$ where $B\otimes \mathfrak{m}_y$ is globally generated is open I got this question when reading Lazarsfeld's book "Positivity in algebraic geometry I". It's example 1.2.9. He claimed the following:
"Let $B$ be a globally generated line bundle on a complete variety $X$, then
$$U:=\{y\in X|B\otimes\mathfrak{m}_y\text{ is globally generated}\}$$
is an open subset of $X$."
His argument says that using Nakayama's lemma, we just need to prove the openness of the set
$$V:=\{y\in X| H^0(X,B)\rightarrow B\otimes \mathcal{O}_X/\mathfrak{m}_y^2\text{ is surjective}\}.$$
This makes some sense to me. The varieties in his book are over $\mathbb{C}$, and for any (closed) point $y$, one has $\mathcal{O}_X/\mathfrak{m}_y=\mathbb{C}$. So the surjectivity above implies that $H^0(X,B)$ surjects to $\mathfrak{m}_yB_y/\mathfrak{m}_y^2B_y$. Note that the map above is a $\mathbb{C}$-vector space homomorphism. However I'm not sure why we don't need to worry about points other than $y$. So that's my first confusion.
I am also confused about how he proved the openness of $V$. He considered the map
$$u:H^0(X,B)\otimes \mathcal{O}_X\rightarrow \mathcal{P}$$
where $\mathcal{P}$ is some sheaf whose fibers are $B\otimes \mathcal{O}_X/\mathfrak{m}_y^2$ for any $y$. He says $V$ is then just the locus where $u$ is surjective. But I thought after tensoring $\mathcal{O}_X$ with $H^0(X,B)$, it is surjective automatically, by globally generation of $B$. Did I miss something?
If not, how should I fix it?
 A: For the first 'confusion':
to see $V$ is open implies $U$ is open. We simply claim that $V=U$.
Let $y\in U$ be a closed point. Let $m_y$ denote the ideal sheaf of $y$ in $X$. Now the global generation means that $$\oplus_{H^0(X, B\otimes m_y)}\mathcal{O}_X\to B\otimes m_y$$ is surjective.  In particular,
$$\oplus_{H^0(X, B\otimes m_y)}\mathcal{O}_X\to B\otimes m_y\to B\otimes \dfrac{m_y}{m_y^2}$$
is surjective.
Consider the cokernel $C$ of the map $$\phi:\oplus_{H^0(X, B)}\mathcal{O}_X\to B\otimes \mathcal{O}_X/m_y^2.$$ Now $m_yC=0$ as $y\in U$. Thus by Nakayama lemma, $C=0$. Thus, $y\in V.$ So $U\subseteq V.$
The converse is clear (as you have already noticed it) so $V\subseteq U$. So $V=U.$
Now openness of $V$:
Once there is a map
$$u:H^0(X, B)\otimes \mathcal{O}_X\to \mathcal{P}$$ $y\in V$ iff $u(y)$
is surjective.
As observed in the text, $Coker(u)$ is a coherent sheaf, so if its stalk at $y$ is 0, then it is 0 in a neighbourhood of $y$, implying that u restricted to a neighbourhood $V_y$ of $y$ is surjective.
Thus, for any $x\in V_y, u(x)=u|_{V_y}(x)$ is surjective.
So $V_y\subseteq V.$
Hopefully this helps.
