
Continuing with our discussion of German/Polish history/languages/genetics, let’s look at what some actual geneticists have to say.
(If you’re joining us for the first time, the previous two posts summarize to: due to being next door to each other and having been invaded/settled over the millennia by groups which didn’t really care about modern political borders, Polish and German DNA are quite similar. More recent events, however, like Germany invading Poland and trying to kill all of the Poles and ethnic Germans subsequently fleeing/being expelled from Poland at the end of the war have created conditions necessary for genetic differentiation in the two populations.)
So I’ve been looking up whatever papers I can find on the subject.
In Contemporary paternal genetic landscape of Polish and German populations: from early medieval Slavic expansion to post-World War II resettlements, Rebala et al write:
The male genetic landscape of the European continent has been shown to be clinal and influenced primarily by geography rather than by language.1 One of the most outstanding phenomena in the Y-chromosomal diversity in Europe concerns the population of Poland, which reveals geographic homogeneity of Y-chromosomal lineages in spite of a relatively large geographic area seized by the Polish state.2 Moreover, a sharp genetic border has been identified between paternal lineages of neighbouring Poland and Germany, which strictly follows a political border between the two countries.3 Massive human resettlements during and shortly after the World War II (WWII), involving millions of Poles and Germans, have been proposed as an explanation for the observed phenomena.2, 3 Thus, it was possible that the local Polish populations formed after the early Slavic migrations displayed genetic heterogeneity before the war owing to genetic drift and/or gene flow with neighbouring populations. It has been also suggested that the revealed homogeneity of Polish paternal lineages existed already before the war owing to a common genetic substrate inherited from the ancestral Slavic population after the Slavs’ early medieval expansion in Europe.2 …
We used high-resolution typing of Y-chromosomal binary and microsatellite markers first to test for male genetic structure in the Polish population before massive human resettlements in the mid-20th century, and second to verify if the observed present-day genetic differentiation between the Polish and German paternal lineages is a direct consequence of the WWII or it has rather resulted from a genetic barrier between peoples with distinct linguistic backgrounds. The study further focuses on providing an answer to the origin of the expansion of the Slavic language in early medieval Europe. For the purpose of our investigation, we have sampled three pre-WWII Polish regional populations, three modern German populations (including the Slavic-speaking Sorbs) and a modern population of Slovakia. …
AMOVA in the studied populations revealed statistically significant support for two linguistically defined groups of populations in both haplogroup and haplotype distributions (Table 2). It also detected statistically significant genetic differentiation for both haplogroups and haplotypes in three Polish pre-WWII regional populations (Table 2). The AMOVA revealed small but statistically significant genetic differentiation between the Polish pre-war and modern populations (Table 2). When both groups of populations were tested for genetic structure separately, only the modern Polish regional samples showed genetic homogeneity (Table 2). Regional differentiation of 10-STR haplotypes in the pre-WWII populations was retained even if the most linguistically distinct Kashubian speakers were excluded from the analysis (RST=0.00899, P=0.01505; data not shown). Comparison of Y chromosomes associated with etymologically Slavic and German surnames (with frequencies provided in Table 1) did not reveal genetic differentiation within any of the three Polish regional populations for all three (FST, ΦST and RST) genetic distances. Moreover, the German surname-related Y chromosomes were comparably distant from Bavaria and Mecklenburg as the ones associated with the Slavic surnames (Supplementary Figure S2). MDS of pairwise genetic distances showed a clear-cut differentiation between German and Slavic samples (Figure 2). In addition, the MDS analysis revealed the pre-WWII populations from northern, central and southern Poland to be moderately scattered in the plot, on the contrary to modern Polish regional samples, which formed a very tight, homogeneous cluster (Figure 3).

This all seems very reasonable. Modern Poland is probably more homogenous than pre-war Poland in part because modern Poles have cars and trains and can marry people from other parts of Poland much more easily than pre-war Poles could, and possibly because the war itself reduced Polish genetic diversity and displaced much of the population.
Genetic discontinuity along the Polish-German border also makes sense, as national, cultural, and linguistic boundaries all make intermarriage more difficult.
The Discussion portion of this paper is very interesting; I shall quote briefly:
Kayser et al3 revealed significant genetic differentiation between paternal lineages of neighbouring Poland and Germany, which follows a present-day political border and was attributed to massive population movements during and shortly after the WWII. … it remained unknown whether Y-chromosomal diversity in ethnically/linguistically defined Slavic and German populations, which used to be exposed to intensive interethnic contacts and cohabit ethnically mixed territories, was clinal or discontinuous already before the war. In contrast to the regions of Kaszuby and Kociewie, which were politically subordinated to German states for more than three centuries and before the massive human resettlements in the mid-20th century occupied a narrow strip of land between German-speaking territories, the Kurpie region practically never experienced longer periods of German political influence and direct neighbourhood with the German populations. Lusatia was conquered by Germans in the 10th century and since then was a part of German states for most of its history; the modern Lusatians (Sorbs) inhabit a Slavic-speaking island in southeastern Germany. In spite of the fact that these four regions differed significantly in exposure to gene flow with the German population, our results revealed their similar genetic differentiation from Bavaria and Mecklenburg. Moreover, admixture estimates showed hardly detectable German paternal ancestry in Slavs neighbouring German populations for centuries, that is, the Sorbs and Kashubes. However, it should be noted that our regional population samples comprised only individuals of Polish and Sorbian ethnicity and did not involve a pre-WWII German minority of Kaszuby and Kociewie, which owing to forced resettlements in the mid-20th century ceased to exist, and also did not involve Germans constituting since the 19th century a majority ethnic group of Lusatia. Thus, our results concern ethnically/linguistically rather than geographically defined populations and clearly contrast the broad-scale pattern of Y-chromosomal diversity in Europe, which was shown to be strongly driven by geographic proximity rather than by language.1 …
Two main factors are believed to be responsible for the Slavic language extinction in vast territories to the east of the Elbe and Saale rivers: colonisation of the region by the German-speaking settlers, known in historical sources as Ostsiedlung, and assimilation of the local Slavic populations, but contribution of both factors to the formation of a modern eastern German population used to remain highly speculative.8 Previous studies on Y-chromosomal diversity in Germany by Roewer et al17 and Kayser et al3 revealed east–west regional differentiation within the country with eastern German populations clustering between western German and Slavic populations but clearly separated from the latter, which suggested only minor Slavic paternal contribution to the modern eastern Germans. Our ancestry estimates for the Mecklenburg region (Supplementary Table S3) and for the pooled eastern German populations, assessed as being well below 50%, definitely confirm the German colonisation with replacement of autochthonous populations as the main reason for extinction of local Slavic vernaculars. The presented results suggest that early medieval Slavic westward migrations and late medieval and subsequent German eastward migrations, which outnumbered and largely replaced previous populations, as well as very limited male genetic admixture to the neighbouring Slavs (Supplementary Table S4), were likely responsible for the pre-WWII genetic differentiation between Slavic- and German-speaking populations. Woźniak et al18 compared several Slavic populations and did not detect such a sharp genetic boundary in case of Czech and Slovak males with genetically intermediate position between other Slavic and German populations, which was explained by early medieval interactions between Slavic and Germanic tribes on the southern side of the Carpathians. Anyway, paternal lineages from our Slovak population sample were genetically much closer to their Slavic than German counterparts. …
Note that they are discussing paternal ancestry. This does not rule out the possibility of significant Slavic maternal ancestry. Finally:
Our coalescence-based divergence time estimates for the two isolated western Slavic populations almost perfectly match historical and archaeological data on the Slavs’ expansion in Europe in the 5th–6th centuries.4 Several hundred years of demographic expansion before the divergence, as detected by the BATWING, support hypothesis that the early medieval Slavic expansion in Europe was a demographic event rather than solely a linguistic spread of the Slavic language.

I left out a lot of interesting material, so I recommend reading the complete discussion if you want to know more about Polish/German genetics.
But what about the maternal contribution? Luckily for us, Malyarchuk et al have written Mitochondrial DNA analysis in Poles and Russians:
Mitochondrial DNA (mtDNA) sequence variation was examined in Poles (from the Pomerania-Kujawy region; n = 436) and Russians (from three different regions of the European part of Russia; n = 201)… The classification of mitochondrial haplotypes revealed the presence of all major European haplogroups, which were characterized by similar patterns of distribution in Poles and Russians. An analysis of the distribution of the control region haplotypes did not reveal any specific combinations of unique mtDNA haplotypes and their subclusters that clearly distinguish both Poles and Russians from the neighbouring European populations. The only exception is a novel subcluster U4a within subhaplogroup U4, defined by a diagnostic mutation at nucleotide position 310 in HVS II. This subcluster was found in common predominantly between Poles and Russians (at a frequency of 2.3% and 2.0%, respectively) and may therefore have a central-eastern European origin. …
The analysis of mtDNA haplotype distribution has shown that both Slavonic populations share them mainly with Germans and Finns. The following numbers of the rare shared haplotypes and subclusters were found between populations analyzed: 10% between Poles and Germans, 7.4% between Poles and Russians, and 4.5% between Russians and Germans. A novel subcluster U4-310, defined by mutation at nucleotide position 310 in HVS II, was found predominantly in common between Poles and Russians (at frequency of 2%). Given the relatively high frequency and diversity of this marker among Poles and its low frequency in the neighbouring German and Finnish populations, we suggest a central European origin of U4-310, following by subsequent dispersal of this mtDNA subgroup in eastern European populations during the Slavonic migrations in early Middle Ages.
In other words, for the most part, Poles, Russians, Germans, and even Finns(!) (who do not speak an Indo-European language and are usually genetic outliers in Europe,) all share their maternal DNA.
Migrants, immigrants, and invaders tend disproportionately to be male (just look at any army) while women tend to stay behind. Invading armies might wipe each other out, but the women of a region are typically spared, seen as booty similar to cattle to be distributed among the invaders rather than killed. Female populations therefore tend to be sticky, in a genetic sense, persisting long after all of the men in an area were killed and replaced. The dominant Y-chromosome haplogroup in the area (R1a) hails from the Indo-European invasion (except in Finland, obviously,) but the mtDNA likely predates that expansion.
These data allow us to suggest that Europeans, despite their linguistic differences, originated in the common genetic substratum which predates the formation of the most modern European populations. It seems that considerable genetic similarity between European populations, which has been revealed by mtDNA variation studies, was further accelerated by a process of gene redistribution between populations due to the multiple migrations occurring in Europe during the past milenia…
It is interesting, though, that recent German invasions of Poland left very little in the way of a genetic contribution. I’d wager that WWII was quite a genetic disaster for everyone involved.
If you want more information, Khazaria has a nice list of studies plus short summaries on Polish DNA.